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.
How to specify the path to object files in the linker command file if there are two build configurations (C67xx with CodeGeneration Tools 6.1.19)?
I want to put .text from the file a.obj in the section iram_text but I get the linker error "cannot find file a.obj".
In the section part of my linker.cmd I have:
iram_text > INT_RAM { a.obj(.text) }
When I use the relative path to a.obj it works:
iram_text > INT_RAM { ..\Output\Release\obj\a.obj(.text) }
But this is not an option, since I have two project configurations (Debug and Release), generating the the object files into different output directories.
I've tried it using the search path option (-i"$(Proj_dir)..\Output\Release\obj"), since this can be set for each configuration, but it doesn't work.
Is there any way to tell the linker where to find the a.obj file?
Stefan,
Are you using CCS to build your project? If so, the paths to the Debug/Release configurations should already be handled correctly by CCS. Please take a look at this related post on a similar topic: http://e2e.ti.com/support/development_tools/code_composer_studio/f/81/p/113303/403579.aspx#403579
If you're building outside of CCS, you could try using preprocessor directives such as #if/#endif within the linker command file and control the allocation based on a defined macro for each build configuration. The preprocesor support in the linker is documented in the C6000 Assembly Language Tools Users Guide. Hope this helps.