DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 
Using programming tools

Header files

Header files contain information such as the following:

Header files are called on #include lines at the beginning of the code. They must conform to C programming style, since they are accessed as part of the code by the compiler. In general, #include statements are placed at the beginning of the code to ensure that they affect the entire code. However, if the intended scope of a particular #include line is only specific to a few lines of code, that #include line can be located anywhere throughout the code.

The Development System contains many header files under the /usr/include directory. Header files accessed only by user-level code are not in the /usr/include directory itself, and header files accessed by drivers and other kernel-level code are in the /usr/include/sys directory. All header files created specifically for an application should be stored in that source tree so they can be retrieved easily after a software upgrade replaces the contents of the /usr/include tree. This is important if the product is to be distributed to all users.


Next topic: Error handling
Previous topic: Program structure

© 2003 Caldera International, Inc. All rights reserved.
SCO OpenServer Release 5.0.7 -- 11 February 2003