Compiler Input File Types

IBM C and C++ Compilers uses file extensions to distinguish between the different types of files it uses. The default file extensions are:

.asm assembler listing file .lst listing file
.c C source file .lib library file
.cod assembler listing file with machine code .m temporary file
.cpp C++ source file .map map file
.cxx C++ source file .obj object file
.ctn temporary file .res resource file
.def definition file .pch precompiled header file
.dll dynamic link library .pdb browser file
.exe executable file .w temporary file
h C header file .wh temporary file
.hpp C++ header file .wi temporary file
.i preprocessor output file .ws temporary file
.l temporary file    

Filename Rules

For example, when you are using IBM C and C++ Compilers defaults, the command:

   icc  module1.c  module2.obj  mylib.lib

compiles the source code file module1.c and produces the object file module1.obj. When the linker is invoked, the object files module1.obj (created during this invocation of the compiler) and module2.obj (created previously), and the library file mylib.lib are passed to the linker. The result is an executable file called module1.exe.



Compiler Output


Summary of Compiler Options