Create a Hello World Executable for BeagleBoard

1k views Asked by At

I am trying to run a HelloWorld project on BeagleBoard. For this I am using RVDS to create the library and then CodeSourcery to create the executable for BeagleBoard.

To create a library through RVDS I am using below command line:

armcc --cpu cortex-a8 -c hello_world.c --c99 --apcs=/fpic --no_hide_all -O3 -Otime --vectorize --no_unaligned_access -I"D:\RVDS\hello_world" -I"C:\Program Files\ARM\RVCT\Data\4.1\713\include\windows"

But this command line only creates object files and not the library. To create the library I used armar command, but I am not sure if this is correct. Hence my first question is how can I create a library using RVDS command line.

I also tried creating the library using RVDS eclipse environment by selecting a new Static Library project. Once the library was created I used CodeSourcery to create the executable using:

arm-none-linux-gnueabi-gcc -Wall -I. -L. test_hello_world.c -lhello_world -o test_hello_world

But if I try to run this executable on BeagleBoard, it doesn't work. Hence I think there is something wrong in the way I am creating the library.

Please let me know if someone has tried the combination of RVDS & CodeSourcery to create an executable for BeagleBoard.

Thanks for your help.

1

There are 1 answers

4
nathan On

If the beagle board is running Linux you can use the device's version of gcc to compile your hello world. That way you don't have to setup a cross compiler on the desktop.