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.

CCS/LAUNCHXL-CC1352P: Linked Resources not saved

Part Number: LAUNCHXL-CC1352P


Tool/software: Code Composer Studio

Hi all,

I want to add some paths to my project so that I can use a path relative to the linked resource path when specifying header files in my .c files. For example, if my header file lives in /Applications/ti/audiofolder/source/ti/audio/audio.h, I would like to include /Applications/ti/audiofolder/source as a linked resource and specify a #include <ti/audio/audio.h> in my .c files.

I went to Project->Properties->Resource->Linked Resources->Path Variables, and added the path '/Applications/ti/audiofolder/source' with name such as AUDIO_SOURCE. I was then able to see AUDIO_SOURCE in the path variables with the specified path. I said 'Apply and Close', and opened the Project->Properties->Resource->Linked Resources->Path Variables to check if it had been saved, and it had not been saved.

Please advise me on how to add a linked resource and have it be saved.

Warm regards,

Samyukta

  • Samyukta,

    Samyukta Ramnath1 said:
    I went to Project->Properties->Resource->Linked Resources->Path Variables, and added the path '/Applications/ti/audiofolder/source' with name such as AUDIO_SOURCE. I was then able to see AUDIO_SOURCE in the path variables with the specified path. I said 'Apply and Close', and opened the Project->Properties->Resource->Linked Resources->Path Variables to check if it had been saved, and it had not been saved.

    That is odd. It should have been saved. But you actually need to do something different for what you want to achieve. See below.

    Samyukta Ramnath1 said:
    For example, if my header file lives in /Applications/ti/audiofolder/source/ti/audio/audio.h, I would like to include /Applications/ti/audiofolder/source as a linked resource and specify a #include <ti/audio/audio.h> in my .c files.

    What you want to create for this is a build variable. You can create it from Project Properties->Build->Variables tab. Then you add that variable to the compiler's include search path (under Project Properties->Build->Compiler->Include Options->--include_path. This will add the directory that the variable points to the #include file search path list.

    This article expands a bit on the difference between build variables and linked resource path variables. 
    http://software-dl.ti.com/ccs/esd/documents/ccs_portable-projects.html#variables