New to Toolchain -- Basic Usage Info Needed

Asked by jsolderitsch

I am trying to build applications for the TI cc2538dk using the Contiki source code as a basis.

I am running on a Mac: OS X Mavericks. I downloaded the ARM toolchain and I have the folder: gcc-arm-none-eabi-4_8-2014q3 installed under my user account.

I also have Xcode installed including the gcc command line tools that go with it.

The Make files for the contiki examples will need to use the arm version of gcc of course but what is the easiest/most trouble free way to get the make commands I run for the contiki examples to use all of the gcc bits that belong to the arm release. Do I just adjust my PATH environment variable? If so, what bin directories do I need to place ahead of /usr/bin to accomplish this? Or do I have to tweak the makefiles instead.

I tried searching for this info but could not locate it. I have built software using make before but only when the target was Mac OS X.

Any pointers appreciated.

Jim

Question information

Language:
English Edit question
Status:
Solved
For:
GNU Arm Embedded Toolchain Edit question
Assignee:
No assignee Edit question
Solved by:
jsolderitsch
Solved:
Last query:
Last reply:
Revision history for this message
Terry Guo (terry.guo) said :
#1

To use the arm tool chain, you have to make the path to tool chain appear firstly in your PATH variable. The command to do so looks like:

export PATH=/work/terguo01/tools/gcc-arm-none-eabi-4_8-2014q3/bin:$PATH

And there are samples under path gcc-arm-none-eabi-4_8-2014q3/share/gcc-arm-none-eabi/samples, you can use them as starting point.

Revision history for this message
jsolderitsch (james-j-solderitsch) said :
#2

Thanks for the reply. I did that simple path change and I was able to compile some source examples I had. So I will mark this question solved.

BUT, the firmware I create in this way on the Mac, when flashed to the device, does not work. It gets hung at the initialization process when the board is switched on.

If I take the same code, compile it inside of the Contiki 2.7 VM (which has a much older tool chain) and then flash the image to the device, the device functions as expected.

So something is not right. I wonder if the case insensitivity of the Mac file system perhaps might be to blame. The compiled image from the Mac is shorter than the one produced on the VM, but that might be optimization gains in the newer tool chain.

I have asked for advice on the Contiki Developer's Mailing List as well.