开发者

what does #include <crtdll/stddef.h> mean?

开发者 https://www.devze.com 2023-01-26 21:46 出处:网络
I am trying to compile the Scintilla control with MSVC++ 2010 Express Edition, and it\'s quite painful getting it to work right because I need a bunch of files. When compiling SString.h, I noticed thi

I am trying to compile the Scintilla control with MSVC++ 2010 Express Edition, and it's quite painful getting it to work right because I need a bunch of files. When compiling SString.h, I noticed this:

#include <crtdll/stddef.h>

I am no C++ programmer, but I do understand what

开发者_运维问答
#include <xxx.h> 

means, but what does the the that include mean? I get the following error with it:

Error 1 error C1083: Cannot open include file: 'crtdll/stddef.h': No such file or directory f\scintilla\lexers\sstring.h 44

Any help on how I could fix it would be appreciated.


If I am not mistaken, that is just a relative path. In other words, Visual Studio will look for stddef.h in the crtdll subdirectory of, probably, the root directory of the project.


By using the preceding function, you are summoning, and subsequently inserting a header file into your current source code.

In the case of #include <crtdll/stddef.h> you will be inserting the stddef.h header file from the crtdll directory (which should be a child folder defined in your compiler as the holding pen for header files) during the compilation and linking of your program.

By inserting the stddef.h header file into your source you are giving your program the capability to wield NULL pointer constants, which are exceedingly useful in some of the more advanced programs you may or may not have come across.

Good luck with your program!


I am no C++ programmer, but I do understand what

are you sure? include with <> searches the include paths for the specified file and copies the content the content of that file in your .cpp. So you are just missing the crtdll/stddef.h file, however stddef.h actually belongs to the C standardlibrary so you might replace it with #include in C or #include in C++ The easiest way would be to check your include directories. crtdll is the C standard library provided by msvc, so maybe you have to add the parent folder of your standard library include directory


This means that stddef.h needs to be included from the crtdll folder.

You need to check your include directories for Visual C++ projects to see that which are the default directories from where Visual Studio looks up for header files.

To fix this error, see that at which path have you installed the Scintilla control. The crtdll folder will be there most probably. And then, add this folder to your visual studio include directories.

You can set it in the following project properties dialog:

Here http://i56.tinypic.com/2zo9guh.jpg

0

精彩评论

暂无评论...
验证码 换一张
取 消