HP aC++/HP C A.06.20 Programmer's Guide
Files on the aCC Command Line
Files containing source or object code to be compiled or linked by HP aC++ can be any
of these files:
• A C++ Source File (.C file)
• Preprocessed Source Files (.i Files)
• Assembly Language Source Files (.s Files)
• Object Files (.o Files)
• Library Files (.a and .so Files)
• Configuration Files (.conf Files)
Unless you use the -o option to specify otherwise, all files that the aCC compiling
system generates are put in the working directory, even if the source files are from
other directories.
C++ Source File (.C file)
You must name the HP aC++ source files with extensions beginning with either .c or
.C, possibly followed by additional characters. If you compile only, for example by
using -c, each C++ source file produces an object file with the same file name prefix
as the source file and a .o file name suffix.
However, if you compile and link a single source file into an executable program in
one step, the .o file is automatically deleted, unless -g is used without +noobjdebug.
NOTE: HP recommends that your source files have .c or .C extensions only, without
any additional characters. While extensions other these are permitted for portability
from other systems, they may not be supported by HP tools and environments.
Preprocessed Source Files (.i Files)
Files with .i extensions are assumed to be preprocessor output files. These files are
processed in the same way as .c or .C files, except that the preprocessor is not run on
the .i file before the file is compiled.
Use the -P or the -E compiler option to preprocess a C++ source file without compiling
it.
Assembly Language Source Files (.s Files)
Files with names ending in .s are assumed to be assembly source files. The compiler
invokes the assembler through cc to create .o files from these.
Use the -S option to compile a C++ source file to assembly code and put the assembly
code into a .s file.
Files on the aCC Command Line 31