SourceForge has been redesigned. Learn more.

Newbie cannot build with CodeSourcery Lite

  • Stephen Miller

    Stephen Miller - 2010-12-06

    I recently got a STM32 Discovery Board and was searching for some demo code that would build under GCC.  I found the tutorial page and downloaded 2.1.4.  I am using CodeSourcery Lite and unfortunately cannot get the demos to build.  The first error was stating that "test" was not recognized command.  Since their is some source code with the name "test" also, I spun my wheels for a long time trying to see why it was building that first and what the problem could be.  I finally realized that there were multiple makefiles being called and the issue was with rules.mak.   The line:
    ENSUREBUILDDIR = $(shell test -d $(BUILDDIR) || mkdir $(BUILDDIR))

    Seems to be trying to get to some OS command called test.   I also downloaded the last stable release.  The only thing I could get to build out of that release was the ATMEL stuff, which uses a different compiler port.   I stole the test.exe from the WINAVR stuff and put it into the CodeSourcery folder.  The test error is gone, but I still cannot get past the first C source code it tries to compile.   The error seems to be generating the first dependency file,

    fatal error: opening dependency file .dep/vectors.o.d:  No such file or directory

    Perhaps this is because my stolen test.exe is compatible with this compiler.  Perhaps I am doing something else wrong.


    1.  Does ChibiOS build under Code Sourcery Lite using Windows XP?
    2.  Does it require something else installed?
    3.  Any hints on what I should try next?


  • Giovanni Di Sirio


    ChibiOS/RT builds correctly using CodeSourcery, you need also some unix-like commands however, Code Sourcery does not provide those for some reason.

    You can install cygwin or the YAGARTO tools:

    Install the tools and make sure that the PATH environment variable points to them too, the demos should build correctly after that.


  • Frank J. Beckmann

    The missing dependency is fixed in ChibiOS  2.1.5.

  • Stephen Miller

    Stephen Miller - 2010-12-08

    Thank you for the very fast reply.  The hint to use the YAGARTO tools was spot on.  It all built fine after installing their tools and their version of the compiler.   For any other newbie wanting to try out their $11 toys, I would recommend starting with the YAGARTO stuff.  However, please read their website carefully.  Windows will want to default to a folder in "Program Files".  However, this will not work because of the space in the file name.  Do not use the default install location.  Pick another folder without any spaces in the folder name.

  • Liam Staskawicz

    Liam Staskawicz - 2010-12-08

    (just finishing this thread on the old forum…)

    You can still use the CodeSourcery compiler (they've just made a new release BTW) - in that case you only need to install the 'YAGARTO tools' package and not the YAGARTO toolchain itself, and then run the latest latest CodeSourcery installer.  This works for me no problem.


Log in to post a comment.