Newbie question

Started by marc77, February 13, 2013, 03:49:44 pm

Previous topic - Next topic


Hello all,
I'm ver new to linux driven boards and have a question that will probably make you laugh   :o.
What do I need to build applications running on such boards? I guess the compiler isn't onboard.
Could you please suggest me some tutorial or quickreference guide to refer to?

Thank you very much and have a good day!!!!



There are quite a lot of different tutorials around, but maybe the best way is just start experimenting yourself with small pieces of code..
First thing you need is a cross compiler, since your PC runs on x86, and this board on ARM architecture, you need a compiler that can create ARM code. You can compile them yourself, or there are also tools that do it automatically for your (buildroot) and also there is the easy way in ie. Ubuntu, just to install them. In Ubuntu the cross compiler can be found in the package manager:
sudo apt-get install gcc-4.6-arm-linux-gnueabi
sudo apt-get install g++-4.6-arm-linux-gnueabi

After that you can cross compile C/C++ apps with these tools
gcc-4.6-arm-linux-gnueabi -o executable main.c

If you transfer that file to the board, it will run, as long as the libraries you used are present also there (for a quick fix you can add -static flag to the build)

Anyway, that should get you started, look into cross compiling, and compiling for arm on linux etc, there is plenty of info around


Thanks you very much for your reply,
your answer was very helpful!!

Have a good day!!!