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.

XDCtools - Missing common.bld file?



Hi,

I'm trying to get in-depth understanding of the XDCtools system.
I wanted to see how I can regenerate all the automatic headers in the xdc.runtime package e.g. xdc/runtime/System.h
So I tried following the procedure described here: http://rtsc.eclipse.org/docs-tip/Working_with_xdc.runtime
But I discovered that I get and error because all the target/config.bld files include common.bld file which is not found in the package.

What do I miss?

Best,
Vasili

  • Vasili,

    The xdc build is picking up the wrong config.bld. Make sure you have a config.bld in the directory you are trying to rebuild as mentioned in the link: http://rtsc.eclipse.org/docs-tip/Working_with_xdc.runtime#Setup_for_xdc_builds

    Hope it helps.

    Vikram

  • Hi Vikram,

    The command I run (from Windows command prompt):

    cd C:\TI\xdctools_3_25_02_70\packages\gnu\targets\arm
    ..\..\..\..\xdc.exe clean

    Please note that the specified directory has config.bld file. But nevertheless I got the following error:

    making package.mak (because of package.bld) in order to clean ...
    js: "./config.bld", line 10: Error: utils.loadCapsule: can't find 'common.bld' a
    long the path 'C:\TI\xdctools_3_25_02_70\packages\gnu\targets\arm/;C:/TI/xdctool
    s_3_25_02_70/packages;../../..;'

    Best,
    Vasili

  • Vasili,

    Are you trying to rebuild gnu\targets\arm targets directory? Or do you want to rebuild xdc.runtime libraries for a particular target?

    To rebuild sources of xdc.runtime, you should cd into one of the rts package (i.e. rtsv5T, rtsv6, rtsv7A, rtsv7M), add a config.bld and build it.

    Vikram

  • Hi Vikram,

    I'm just trying to understand how I can rebuild everything (in case i want to add some modifications).

    "add config.bld and build it" - Where do I take this config.bld?

    I'm having difficulty understanding how all this redistributed package was built initially at first place. All the config.bld files try loading this "common.bld" file which isn't found anywhere. What is this file? Where does it come from?

    Best,
    Vasili

  • Vasili,

    Can you please explain what modifications you would want to do? It would be easier to help if I understand exactly what you are trying to do.

    It is not possible to re-build the entire XDC product. Only some of the packages are re-buildable. As you noticed, there are some files which are specific to our build environment and hence they are not included in the final product. One of them being the "common.bld" file which contains target information and path to code generation tools root directories.

    If you want to understand about XDC packages in general. Please go through these tutorials - http://rtsc.eclipse.org/docs-tip/RTSC_Programming.

    For information and an example of a config.bld file, have a look at the "Setup for xdc builds" - http://rtsc.eclipse.org/docs-tip/Working_with_xdc.runtime#Setup_for_xdc_builds.

    Let me know if you need more information.

    Vikram

  • Ok, let's start from simple case. Say I want to rebuild the gnu.targets.arm.rtsv7A package for A8F target (For example if I modify code it startup.c)

    Another example - I want to modify gnu.targets.arm.A8F (xdc and xs), say I want to change the provided build profiles/default compiler flags. How then I rebuild the package?

  • To rebuild gnu.targets.arm.rtsv7A for A8F target, create a config.bld file in the package gnu.targets.arm.rtsv7A

    The config.bld will look like this:

    /* specify the compiler installation directory for the targets we need */
    var A8F = xdc.module("gnu.targets.arm.A8F");
    var tools = java.lang.System.getenv("TI_DIR"); /* TI_DIR would be the CCS installation dir: C:/ti/ccsv5 */
    A8F.rootDir = tools + "/tools/compiler/gcc-arm-none-eabi-4_7-2012q4"; /* Change gcc-arm-none-eabi-4_7-2012q4 to the gcc arm directory in your CCS installation */
     
    /* specify the target(s) to use when building source files */
    var Build = xdc.module("xdc.bld.BuildEnvironment");
    Build.targets = [A8F];         /* only build using A8F target */

    Now, follow the steps in http://rtsc.eclipse.org/docs-tip/Working_with_xdc.runtime and rebuild.

    %cd ..../packages/gnu/targets/arm/rtsv7A
    %xdc clean
    %xdc


    To rebuild a target gnu.targets.arm.A8F.

    Files with extension .xs are scripts which are run during build time. So any changes to xs does not require a rebuild.
    If you would want to change files with .xdc, you will need a rebuild to generate the header files (.h).

    In gnu/targets/arm directory, add a empty common.bld file. Make your changes to .xdc file and rebuild by running the  `xdc` command.

    Hope this helps.

    -Vikram

  • Hi Vikram,

    Thanks! This helped.

    Best,
    Vasili

  • Hi Vikram!

    I'm trying my hands on few codecs. When I compile some voice codecs, I get a warning: "config.bld" not found. 

    Where can I find this "config.bld"? Or do I need to create it myself?

    Please help!

    Karan

  • Karan, 

    Do you still have an issue? If yes, can you please create a new thread with detailed info about the issue.

    Thanks,

    Vikram