This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

ARM-CGT: ti_cgt_armllvm_2.1.3.LTS compiler

Part Number: ARM-CGT


Hello, there's an issue from the customer need your help:

I am right now working on ti_cgt_armllvm_2.1.3.LTS compiler.

there is a simple demo in this link https://software-dl.ti.com/codegen/docs/tiarmclang/compiler_tools_user_guide/compiler_manual/linker_description/04_linker_options/basic-options.html

tiarmclang file1.c.o file2.c.o -Wl,--map_file=a.map, 
however when I tried it can not recgonize this option, I changed it to tiarmclang file1.c.o file2.c.o -Wl,-ma, it works the file file is a.
1. why it is different from the document
2. does the linker support output the linker file to a specify path? I tried, it did not work. is there an example?
3. How to invoke the linker script with tiarmclang? is the linker command file similiar to the linker script? I try to invoke a gnu style linker script, seems the linker can not recgonize some
syntax, line number 56 report this issue: expecting output section, GROUP, or UNION instead of "=", how to define a symbol in the linker command file? Is there some example?


Thanks & Regards,
Ben
  • when I tried it can not recgonize this option

    I cannot reproduce that result.  Here is another example.

    C:\examples>type stub_main.c
    int main() {}
    
    C:\examples>tiarmclang stub_main.c -Wl,--rom_model,--map_file=stub_main.map

    If --rom_model is not used, there are other errors unrelated to the map file.  Please ignore that detail for now.

    The stub_main.map file is created as expected.  Does this work for you?

    does the linker support output the linker file to a specify path?

    Continuing the previous example ...

    C:\examples>tiarmclang stub_main.c -Wl,--rom_model,--map_file=stub_main.map -o subdir\stub_main.out

    This creates the executable stub_main.out in the directory subdir.

    How to invoke the linker script with tiarmclang?

    Please see the article Linking: Migrate from Arm GCC to tiarmclang.

    Thanks and regards,

    -George