Migration from MPLAB® C18 to XC8 Compiler

The MPLAB® C18 Compiler is no longer supported, Microchip provides the MPLAB® XC8 compiler instead. We have a "MPLAB C18 to XC8 C Compiler Migration Guide". Another useful document is the "MPLAB XC8 Compiler User's Guide".

XC8 does not use linker scripts, instead, it provides options to control the linking and placement of the code. The compiler will invoke the linker automatically; you don't need to worry about using/invoking the linker unless you have a specific need to do so. XC8 will automatically execute the linker with all the necessary arguments. You will have to translate the C18 Linker Script settings to the equivalent Linker options under XC8.

Using the linker directly is not simple, and should be attempted only by those with a sound knowledge of the compiler, and linking in general.

© 2024 Microchip Technology, Inc.
Notice: ARM and Cortex are the registered trademarks of ARM Limited in the EU and other countries.
Information contained on this site regarding device applications and the like is provided only for your convenience and may be superseded by updates. It is your responsibility to ensure that your application meets with your specifications. MICROCHIP MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY KIND WHETHER EXPRESS OR IMPLIED, WRITTEN OR ORAL, STATUTORY OR OTHERWISE, RELATED TO THE INFORMATION, INCLUDING BUT NOT LIMITED TO ITS CONDITION, QUALITY, PERFORMANCE, MERCHANTABILITY OR FITNESS FOR PURPOSE. Microchip disclaims all liability arising from this information and its use. Use of Microchip devices in life support and/or safety applications is entirely at the buyer's risk, and the buyer agrees to defend, indemnify and hold harmless Microchip from any and all damages, claims, suits, or expenses resulting from such use. No licenses are conveyed, implicitly or otherwise, under any Microchip intellectual property rights.