X: Specify Source Language Option

The -xassembler-with-cpp option allows you to specify that all assembly source files need to be preprocessed, irrespective of the source file’s extension. For example:

xc8-cc -mcpu=18f4520 -xassembler-with-cpp proj.c init.s

will tell the compiler to run the preprocessor over the assembly source file, even though the file name does not use a .S extension.