In the page http://processors.wiki.ti.com/index.php/Portable_Projects_in_CCSv4_for_C2000 's description of a somewhat involved method of circumventing Eclipse's inability to deal with relative pathnames, there is a section entitled "Using Linked Variables in #include Search Path" whose procedure I have attempted to follow:
1) As it describes, I add linked resources SOURCE_ROOT and TIDCS_C2802x_INC to my project. Note that the Enable linked resources box is checked:
2) I update the include paths in the project properties to use the new linked resources, using the ${ } macro expansion syntax it describes, which is matched by that for the predefined CG_TOL_ROOT:
3) However, when I do the build the files in these directories are not foung, and it appears that the linked resources did not get macro-expanded at all as shown in the highlighted text below which appears in the Console window. This remains the case even after exiting and relaunching CCS 4.2.5.00005, and even after reboot. I am also puzzled by the expansion that did succeed, since C:/Program Files/Texas Instruments/ccsv4/tools/compiler/c2000 is defined to be CCS_C2000_6_0_1_CG_ROOT rather than CG_TOOL_ROOT as shown above, although they are clearly related.
The failing #include file is #include'd by a version of DSP2802x_Device.h residing in the project directory which I modified to accommodate local typedefs.
**** Build of configuration Debug for project Piccolo27HwImpl ****
C:\Program Files\Texas Instruments\ccsv4\utils\gmake\gmake -k all
'Building file: C:/Products/bassettb_IFOURXX_4/ifx_Controller/Code/ControllerProcessor/Piccolo/PicUart.cpp.c'
'Invoking: Compiler'
"C:/Program Files/Texas Instruments/ccsv4/tools/compiler/c2000/bin/cl2000" -v28 -mt -ml -g --include_path="C:/Program Files/Texas Instruments/ccsv4/tools/compiler/c2000/include" --include_path="/include" --include_path="/HAL" --include_path="/Application" --diag_warning=225 --preproc_with_compile --preproc_dependency="PicUart.cpp.pp" "C:/Products/bassettb_IFOURXX_4/ifx_Controller/Code/ControllerProcessor/Piccolo/PicUart.cpp.c"
"C:\Products\bassettb_IFOURXX_4\ifx_Controller\Code\ControllerProcessor\Piccolo\Modified_DSP2802x_Device.h", line 132: fatal error: could not open source file "DSP2802x_Adc.h"
1 fatal error detected in the compilation of "C:/Products/bassettb_IFOURXX_4/ifx_Controller/Code/ControllerProcessor/Piccolo/PicUart.cpp.c".
Compilation terminated.
>> Compilation failure
gmake: *** [PicUart.cpp.obj] Error 1
gmake: Target `all' not remade because of errors.
Build complete for project Piccolo27HwImpl
I'm sure that I am missing something simple.
Also, if anyone could explain why Eclipse can't support relative pathnames to begin with I would feel better about this state of affairs.
Thanks,
Bruce Bassett
Cummins-Allison Corp.