This section discusses the mechanisms used by XL C/C++ to specify the search paths for directories containing include files, libraries, and the location of a GNU C or C++ compiler. These mechanisms are environment variables, include files, attributes in a configuration file, and command-line options. The vac_configure utility is provided to facilitate the creation of valid configuration files.
The important search paths for XL C/C++ are the standard directory locations for:
Related Reference
Part of the compilation environment are the search paths for special files such as libraries and include files. The following system variables are used by the compiler.
The command-line interfaces for XL C/C++ are not automatically installed in /usr/bin. To invoke the compiler without having to specify the full path, do one of the following steps:
The NLSPATH environment variable informs the compiler how to find the appropriate message catalogs.
To ensure that the path is correct, issue the following command:
export NLSPATH=$NLSPATH:smprt-path/msg/%L/%N: compiler-path/vacpp/6.0/msg/%L/%N
where smprt-path and compiler-path are the installation locations specified when you installed the packages.
The locations for GNU, IBM, and system header files are most conveniently specified in a configuration file.
The compiler option -I directory_name allows you to add directories to the search paths in the configuration file. The configuration file itself uses the -I option internally to set the directory paths that it controls. The compiler searches the directories specified by -I within the configuration file before searching those specified by -I options on the command line.
See XL C/C++ Compiler Reference for more information.
Related References