C/C++ Programmer's Guide (G06.27+, H06.03+)

Table Of Contents
Preprocessor Directives and Macros
HP C/C++ Programmer’s Guide for NonStop Systems429301-010
12-8
#include
source_specifier
specifies the location of the program text that the compiler includes in the
compilation.
source_file
is the file name of the source file you want to include. In the Guardian
environment, the compiler searches for source_file using the SSV search list.
In the OSS environment, the compiler searches for source_file using operands
specified in the c89 utility -I flag.
library_header_file
is the name of the library header file you want to include. The compiler assumes
that library header files reside in the same volume and subvolume (in the Guardian
environment) or directory (in the OSS environment) as the compiler. In the
Guardian environment, the compiler searches for library_header_file using
the SSV search list. In the OSS environment, the compiler searches for
library_header_file using operands specified in the c89 utility -I flag.
section_list
is a parenthesized, comma-separated list of section names found in the specified
source file or library header file. Sections are created using the SECTION pragma,
which is discussed in SECTION on page 13-85.
This is an HP NonStop extension to the standard.
nolist
directs the compiler not to list the contents of the file or sections being included.
This is an HP NonStop extension to the standard.
newline
is the newline character that terminates the directive line.
Usage Guidelines
You can enter the INCLUDE directive on the command line or in the source text.
The INCLUDE directive specifies a pathname that the compiler searches before
looking in the usual places.
The compiler searches for files:
File File Search
#include <library_header_file> The specified standard header file is
searched for in the location of the
compiler (see details in following bullets).