MPLAB X IDE v6.20: #import() directive added to LST file
Posted: Sat Sep 05, 2026 3:59 am
We compiled the same source code under MPLAB X IDE v6.00 and v6.20 with the CCS C compiler v5.115. The MCU is the PIC18LF47K40.
The HEX files show differences in many places.
The LST files show differences in the assembly code in many places, and the LST file for v6.20 has this extra directive that is not in the original main.c file:
#import(file="build/default/production/main.o")
The main.o file does appear in the folder “build/default/production/”.
This #import directive appears as the first line after some initial assembly code, and immediately after this directive is the main.c code.
Why is this happening, and will the two different HEX files operate the same way on the MCU?
Also, is there any way to configure v6.20 or the CCS C compiler to not add that directive, and is there any advantage in doing so?
Ttelmah
Joined: 11 Mar 2010 Posts: 20126
Posted: Sat Sep 05, 2026 10:44 pm
You need to ask in an MPLAB forum.
However look carefully at how the project is configured. It sounds as if
the version referring to the .o, is configured to generate an object file,
rather than single pass compilation. Also check that the files are in
the same locations in the two projects.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum