SPNU151W January 1998 – March 2023 66AK2E05 , 66AK2H06 , 66AK2H12 , 66AK2H14 , AM1705 , AM1707 , AM1802 , AM1806 , AM1808 , AM1810 , AM5K2E04 , OMAP-L132 , OMAP-L137 , OMAP-L138 , SM470R1B1M-HT , TMS470R1A288 , TMS470R1A384 , TMS470R1A64 , TMS470R1B1M , TMS470R1B512 , TMS470R1B768
You might find it useful to set the compiler, assembler, and linker default options using the TI_ARM_C_OPTION environment variable. If you do this, the compiler uses the default options and/or input filenames that you name TI_ARM_C_OPTION every time you run the compiler.
Setting the default options with these environment variables is useful when you want to run the compiler repeatedly with the same set of options and/or input files. After the compiler reads the command line and the input filenames, it looks for the TI_ARM_C_OPTION environment variable and processes it.
The table below shows how to set the TI_ARM_C_OPTION environment variable. Select the command for your operating system:
Operating System | Enter |
---|---|
UNIX (Bourne shell) | TI_ARM_C_OPTION=" option1 [option2 . . .]"; export TI_ARM_C_OPTION |
Windows | set TI_ARM_C_OPTION= option1 [option2 . . .] |
Environment variable options are specified in the same way and have the same meaning as they do on the command line. For example, if you want to always run quietly (the --quiet option), enable C/C++ source interlisting (the --src_interlist option), and link (the --run_linker option) for Windows, set up the TI_ARM_C_OPTION environment variable as follows:
set TI_ARM_C_OPTION=--quiet --src_interlist --run_linker
The TI_ARM_C_OPTION environment variable takes precedence over the older TMS470_C_OPTION environment variable if both are defined. If only TMS470_C_OPTION is set, it will continue to be used.
Any options following --run_linker on the command line or in TI_ARM_C_OPTION are passed to the linker. Thus, you can use the TI_ARM_C_OPTION environment variable to specify default compiler and linker options and then specify additional compiler and linker options on the command line. If you have set --run_linker in the environment variable and want to compile only, use the compiler --compile_only option. These additional examples assume TI_ARM_C_OPTION is set as shown above:
armcl *c ; compiles and links
armcl --compile_only *.c ; only compiles
armcl *.c --run_linker lnk.cmd ; compiles and links using a command file
armcl --compile_only *.c --run_linker lnk.cmd
; only compiles (--compile_only overrides --run_linker)
For details on compiler options, see Section 2.3. For details on linker options, see the Linker Description chapter in the ARM Assembly Language Tools User's Guide.