Olimex Support Forum

OLinuXino Android / Linux boards and System On Modules => A20 => Topic started by: philmacu on December 18, 2014, 02:58:59 AM

Title: Am I missing something obvious about toolchains?
Post by: philmacu on December 18, 2014, 02:58:59 AM
hi this might be a really dumb question, I have just started exploring the whole embedded linux world. I got two A20s to start with, along with the default Debian image. I installed Linux Ubuntu 12 on a vm installation. Since then I have had a lot of trouble trying to set up a cross compiler. I can compile fine on the device using g++, joe, and gdb . I would like to move to the next stage and cross compile. I have tried both Qt and eclipse. My problem seems to be with the tool chain.
Instead of trying (and failing) to build my own, how come it is not possible to download a pre built one? I imagine the majority of people are using Ubuntu?
If anyone can point me to a downloadable source I would be really really grateful

All the best
phil
Title: Re: Am I missing something obvious about toolchains?
Post by: JohnS on December 18, 2014, 01:05:19 PM
If you follow the various (Olimex & other) tutorials don't they use such toolchains?

Also, is linux-sunxi no help about such?

I forget where I got mine, sorry, it's been a while.  As I recall ARM ones were everywhere the problem was choosing!

John
Title: Re: Am I missing something obvious about toolchains?
Post by: philmacu on December 18, 2014, 01:54:41 PM
Hi John,

I will have a look at the linux-sunxi site. Part of the problem is I start following one thread then end up on another! This is my first interaction with the Linux environment so am a bit confused. Up until know I have been dealing with the ATMEL ATMEGA devices, they don't have an OS as such so its a much simpler matter of just writing the application and running it directly on the device.

Phil
Title: Re: Am I missing something obvious about toolchains?
Post by: JohnS on December 18, 2014, 02:40:58 PM
I suggest to follow an Olimex tutorial as they're quite detailed.  Do read linux-sunxi as well as it's a huge resource.

You don't have to run an OS on AW chips...

(Try building & tweaking u-boot if you fancy that.)

John
Title: Re: Am I missing something obvious about toolchains?
Post by: dudisor on December 20, 2014, 09:56:03 PM
Hi Phil,

I tried two months to crosscompile qt5.3.2 for lime2, but without success. I gave up and installed qt4-sdk package on lime (apt-get install qt4-sdk). Now I installed on the desktop (debian 7) the same package and make the program there and after being satisfied, copy the source on lime2 and recompile it.

Adrian.
Title: Re: Am I missing something obvious about toolchains?
Post by: philmacu on December 21, 2014, 04:51:47 PM
Thanks Adrian, I will give that a try. At the moment I am directly compiling on the A20, I am using Joe to edit the code and g++ and gdb to compile/debug it.
That works fine for console type applications, but needless to say isn't the best way to implement graphics.

Phil
Title: Re: Am I missing something obvious about toolchains?
Post by: kair on December 21, 2014, 06:07:01 PM
Hi Phil,

did you already try to use the arm-linux-gnueabi-gcc from your Ubuntu (gcc-4.x-arm-linux-gnueabi Packages)? These are normally used to build the images for your platform. For Android it is the arm-linux-gnueabihf-gcc.
For a complete toolchain you will need much more like kernel-headers, gnu-headers, headers for your GUI like qt or x-headers, so this needs to be installed in your VM also.

Kind Regards,
Kai
Title: Re: Am I missing something obvious about toolchains?
Post by: philmacu on December 22, 2014, 12:46:48 AM
Hi Kair, I did with some limited success I could get Qt to compile, but it would never execute the binaries on the A20
Title: Re: Am I missing something obvious about toolchains?
Post by: philmacu on December 22, 2014, 09:48:45 PM
I managed to get a solution working via MS Visual Studio and a third party plugin, the advantage for those without a dedicate Linux machine is that this works without any VMWare, the disadvantage is that the third party plugin is not open source and comes with a €100 fee.

You can try it out for 30 days, it uses Visual Studio 2013 Community, which seems to be free. It was very easy to get up and running.

I can imagine that this goes against the whole Linux philosophy, but, until I can find a toolchain that I can easily download and get to work then its this solution for me.

BTW the third party plugin is called VisualGDB - that's not an add, its a statement ;-)