Hi,
I am using a quite complex linker control file which includes a .h with memory addresses. Unfortunately, I get this:
linking....\Objects\XMC7_Library.axf: Error: L6630E: Invalid token start expected number or ( but found H at position 24 on line 162.\Objects\XMC7_Library.axf: Error: L6629E: Unmatched parentheses expecting ) but found H at position 24 on line 162C:\Temp\p5178-3(162): error: L6228E: Expected '{', found 'H...'.C:\Temp\p5178-3(162): error: L6228E: Expected '}', found 'EOF'.Not enough information to list image symbols.Not enough information to list load addresses in the image map.Finished: 2 information, 0 warning and 4 error messages.
How can i find out what is going wrong? I checked braces multiple times but cannot find an error.How can I have a look at the input (.sct) which the linker sees? The temporary file seems to get deleted just after error creation. How can I get the preprocessor output of the .sct?Is there some maximum line length which the linker can handle? Some ob my memory address defines consist of chained defines.Thanks + best regards, Rainer
Solution found:; D:\Keil_v5\ARM\ARMCLANG\bin\armclang.exe -E --target=arm-arm-none-eabi -x c -mcpu=cortex-m7 -D_CORE_CM7_0_ HAL_memoryMap.sct > HAL_memoryMap.txt; HAL_memoryMap.txt contains now the input which the linker sees.; You can set this .txt in the linker settings to check if it is ok.; After your corrections in the .sct, do not forget to uncomment the first line again.
The trick is to comment out the preprocessor call in the linker script and to run it manually, capturing the output in a text file.The lines in the text file are now, what the linker gets and you can see what went wrong. In my case, it was a misspelled define.