7.4.1 Output Files

The compilation driver can produce output files with the following extensions, which are case-sensitive.

Table 7-4. File Names
ExtensionsDefinition
file.hexExecutable file
file.cofCOF debug file (default)
file.elfELF debug file
file.oObject file (intermediate file)
file.SAssembly code file (required preprocessing)
file.sAssembly code file (intermediate file)
file.iPreprocessed file (intermediate file)
file.pPreprocedure abstraction assembly language file (intermediate file)
file.mapMap file

The names of many output files use the same base name as the source file from which they were derived. For example the source file input.c will create an object file called input.o when the -c option is used.

The default output file is a ELF file called a.out, unless you override that name using the -o option.

If you are using MPLAB X IDE to specify options to the compiler, there is typically a project file that is created for each application. The name of this project is used as the base name for project-wide output files, unless otherwise specified by the user. However check the manual for the IDE you are using for more details.

Note: Throughout this manual, the term project name will refer to the name of the project created in the IDE.

The compiler is able to directly produce a number of the output file formats which are used by Microchip development tools.

The default behavior of xc16-gcc is to produce a ELF output. To make changes to the files output or the file names, see sectionDriver Option Descriptions.