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 Version: 6.1.0.00104, XDC Build Error - CC2640 TI-RTOS Project

Other Parts Discussed in Thread: LMT01, SYSBIOS

My project is reporting the following build error, which I don't understand and don't know how to resolve.  Several other people have posted this error but I don't see an explanation of the cause or resolution.  I'm using CCS Version: 6.1.0.00104.

error: xdc.cfg.SourceDir: "C:/TI/xdctools_3_31_01_33_core/packages/xdc/cfg/SourceDir.xs", line 209: xdc.cfg.SourceDir : Build of generated source libraries failed: exit status = 2:

One possible clue is that CCS is adding [TI-RTOS] to this file in the project view.  The exact same .cfg file does not cause the error in another CCS project in which it is not marked with [TI-RTOS] in the project view. 

In the screenshot below, you can see the .cfg file in analog_light_sensor_tirtos project is not labeled as [TI-RTOS] and this builds without error.  The exact same file is added to the cc26xx_LMT01_tirtos project whic has the build error.

 

  • Here is more detail on the error:
    Starting build of library sources ...
    cd C:/Users/a0322160/DOCUME~1/TEXASI~2/SENSOR~1/examples/ruben_comparator_test/source/src
    C:/TI/xdctools_3_31_01_33_core/gmake.exe -f C:/Users/a0322160/DOCUME~1/TEXASI~2/SENSOR~1/examples/ruben_comparator_test/source/src/makefile.libs GEN_SRC_DIR=C:/Users/a0322160/DOCUME~1/TEXASI~2/SENSOR~1/examples/ruben_comparator_test/source/src
    making C:/Users/a0322160/DOCUME~1/TEXASI~2/SENSOR~1/examples/ruben_comparator_test/source/src/sysbios/sysbios.aem3 ...
    gmake[1]: Entering directory `C:/Users/a0322160/DOCUME~1/TEXASI~2/SENSOR~1/examples/ruben_comparator_test/source/src/sysbios'
    Preprocessing library source files ...
    C:/Users/a0322160/AppData/Local/Temp/make4112-2.sh: 1: Syntax error: Unterminated quoted string
    C:/Users/a0322160/AppData/Local/Temp/make4112-3.sh: 1: Syntax error: Unterminated quoted string
    C:/Users/a0322160/AppData/Local/Temp/make4112-4.sh: 1: Syntax error: Unterminated quoted string
    C:/Users/a0322160/AppData/Local/Temp/make4112-6.sh: 1: Syntax error: Unterminated quoted string
    C:/Users/a0322160/AppData/Local/Temp/make4112-5.sh: 1: Syntax error: Unterminated quoted string
    C:/Users/a0322160/AppData/Local/Temp/make4112-7.sh: 1: Syntax error: Unterminated quoted string
    C:/Users/a0322160/AppData/Local/Temp/make4112-9.sh: 1: Syntax error: Unterminated quoted string
    C:/Users/a0322160/AppData/Local/Temp/make4112-a.sh: 1: Syntax error: Unterminated quoted string
    C:/Users/a0322160/AppData/Local/Temp/make4112-8.sh: 1: Syntax error: Unterminated quoted string
    C:/Users/a0322160/AppData/Local/Temp/make4112-b.sh: 1: Syntax error: Unterminated quoted string
    C:/Users/a0322160/AppData/Local/Temp/make4112-c.sh: 1: Syntax error: Unterminated quoted string
    C:/Users/a0322160/AppData/Local/Temp/make4112-d.sh: 1: Syntax error: Unterminated quoted string
    C:/Users/a0322160/AppData/Local/Temp/make4112-e.sh: 1: Syntax error: Unterminated quoted string
    C:/Users/a0322160/AppData/Local/Temp/make4112-f.sh: 1: Syntax error: Unterminated quoted string
    gmake[1]: *** [mangled__BIOS_lib.pp] Error 2
    gmake[1]: *** Waiting for unfinished jobs....
    gmake[1]: *** [mangled_ti.sysbios.BIOS_config_lib.pp] Error 2
    gmake[1]: *** [mangled_ti.sysbios.BIOS_RtsGateProxy_config_lib.pp] Error 2
    gmake[1]: *** [mangled_knl_Clock_lib.pp] Error 2
    gmake[1]: *** [mangled_ti.sysbios.knl.Clock_config_lib.pp] Error 2
    gmake[1]: *** [mangled_knl_Idle_lib.pp] Error 2
    gmake[1]: *** [mangled_knl_Intrinsics_lib.pp] Error 2
    gmake[1]: *** [mangled_knl_Event_lib.pp] Error 2
    gmake[1]: *** [mangled_knl_Mailbox_lib.pp] Error 2
    gmake[1]: *** [mangled_ti.sysbios.knl.Mailbox_config_lib.pp] Error 2
    gmake[1]: *** [mangled_knl_Queue_lib.pp] Error 2
    gmake[1]: *** [mangled_ti.sysbios.knl.Queue_config_lib.pp] Error 2
    gmake[1]: *** [mangled_knl_Semaphore_lib.pp] Error 2
    gmake[1]: *** [mangled_ti.sysbios.knl.Semaphore_config_lib.pp] Error 2
    C:/Users/a0322160/AppData/Local/Temp/make4112-10.sh: 1: Syntax error: Unterminated quoted string
    gmake[1]: *** [mangled_knl_Swi_lib.pp] Error 2
    C:/Users/a0322160/AppData/Local/Temp/make4112-1.sh: 1: Syntax error: Unterminated quoted string
    gmake[1]: *** [mangled_knl_Swi_andn_lib.pp] Error 2
    gmake[1]: Leaving directory `C:/Users/a0322160/DOCUME~1/TEXASI~2/SENSOR~1/examples/ruben_comparator_test/source/src/sysbios'
    gmake: *** [C:/Users/a0322160/DOCUME~1/TEXASI~2/SENSOR~1/examples/ruben_comparator_test/source/src/sysbios/sysbios.aem3] Error 2
    Build of libraries failed.
    error: xdc.cfg.SourceDir: "C:/TI/xdctools_3_31_01_33_core/packages/xdc/cfg/SourceDir.xs", line 209: xdc.cfg.SourceDir : Build of generated source libraries failed: exit status = 2:
  • I was able to resolve the error by moving the .cfg file into the CCS project directory. Although I'm not stuck on this anymore, I would like to understand the reason for this error and any resources available to debug similar problems. Thanks
  • The error is most likely caused by white spaces in your directory paths. We do not recommend installing SYS/BIOS and XDCtools in the directories with white spaces because gmake can't handle them.
    The make file being processed at the time when the errors started showing up is source/src/makefile.libs. That file is generated, and it would be useful to compare its content when the build works with the content when the build is not working. I am not sure how would the location of the CFG file change the build, but I guess it's possible.
    If you can post the versions of the file I asked about, I might be able to find a more precise cause of the problem.
  • The error is most likely caused by white spaces in your directory paths. We do not recommend installing SYS/BIOS and XDCtools in the directories with white spaces because gmake can't handle them.
    The make file being processed at the time when the errors started showing up is source/src/makefile.libs. That file is generated, and it would be useful to compare its content when the build works with the content when the build is not working. I am not sure how would the location of the CFG file change the build, but I guess it's possible.
    If you can post the versions of the file I asked about, I might be able to find a more precise cause of the problem.

    Thanks for the information.  The interesting thing is that both paths have white spaces.  Take a look at the two generated files. 

    2021.makefile.libs.local_cfg_file.txt3377.makefile.libs.linked_cfg_file.txt

  • The make file generated when the config script is local to the project contains
    GEN_SRC_DIR=../source/src
    and there are no white spaces in there, while the definition of that variable in the case when the script is in a different project contains white spaces. That variable is later used in compiler's command lines processed by gmake, which is where the errors happen.
    So, you can have your config script in a different project, but the path for that project must not contain spaces.
  • That all seems to make sense, but now I'm getting the error again, even after reverting back to having the .cfg in the local path. I confirmed that the generated make file is identical to the one I attached previously, but I'm still getting the error. ??? This problem seems to be intermittent because when it originally started happening I couldn't pinpoint anything I did to cause it.
  • Is that the same "Unterminated quoted string" error? There is one more relevant file, makefile in src/sysbios. Any white spaces in variables defined in that file could cause problems. Generally, the only fix is not to use paths with white spaces. It's possible that build in a directory with white spaces would work when you change something, and try again without cleaning, and then when you clean it breaks again. But, we don't have a clean workaround, otherwise we wouldn't be recommending reinstalling products.
  • Yes I'm getting the same error.  I even copied the workspace to another location such that there is no whitespace in its path.  I'm attaching the build log and the .cfg file with generated src/ folder.  Please let me know if you see anything I'm doing wrong.

    3731.build_log_09102015.txt6036.source.zip

  • If you search for "Texas" in src/sysbios/makefile, you'll see the include option
    --include_path="C:/Users/a0322160/Documents/Texas
    which is missing a closing quote. That invalid path is a consequence of the white space in "C:/Users/a0322160/Documents/Texas Instruments/Sensor Controller Studio/examples/ruben_comparator_test/source". I think you are defining that include option, so if there is a 8.3 version of that path, try passing that version instead and see if it helps.
  • Ok I see that now. Thanks very much for the help. I'm still scratching my head about how it worked before (a few posts back), but maybe I didn't have include path defined the same way.
  • Guys,

    we just updated our ti-rtos project to the recent sdk / ti-rtos / xdctools and could't compile anything. Even simple examples didn't work. We figures this was caused by the white spaces in the workspace directory.

    I used to work in older ti-releases. 

    Do we have to change our complete directory stricture now?

    ...

  • XDCtools always had a problem with whitespaces, so if you had a setup that worked but it doesn't work now, it could be a different problem. The best way to find out is that you post the complete console output with the error message.
  • XDCTools can't manage dash either.