If you specify the header file using a full (absolute) path name, you can use these methods interchangeably, regardless of the type of header file you want to include. However, if you specify the header file using a relative path name, the compiler uses a different directory search order for locating the file depending on the method used to include the file.
The compiler searches
the standard directory for the XL C headers. The default directory
for these headers is specified in the compiler configuration file.
This is normally /opt/ibmcmp/vac/11.1/include/,
but the search path can be changed with the -qc_stdinc compiler
option.
The compiler searches
the standard directory for the XL C++ headers. The default directory
for these headers is specified in the compiler configuration file. This is normally /opt/ibmcmp/vacpp/11.1/include/,
but the search path can be changed with the -qcpp_stdinc compiler
option.2
The compiler searches
the standard directory for the system headers. The default directory
for these headers is specified in the compiler configuration file. The default location for these headers is specified
in the compiler configuration file. This location is set during installation,
but the search path can be changed with the -qgcc_c_stdinc option.
The compiler searches the
standard directory for the system headers. The default directory for
these headers is specified in the compiler configuration file. The default location for these headers is specified
in the compiler configuration file. This location is set during installation,
but the search path can be changed with the -qgcc_cpp_stdinc option.2