Search code examples
cgccarmbuildroot

Install gcc in 32 bit ARM architecture



I've installed BuildRoot, to set a SoftetherVPN. Well, my problem is that I necessary need to install GCC, in a 32-bit ARM Architecture, (obviously I've downloaded the 32 bit version). I looked all over the internet, because of many problems:

My first idea was to install GCC using command sudo apt-get or sudo yum, but I can only find it in Debian Linux (Buildroot kernel, and its toolchain are very reduced).

At this point I tried to cross-compiling GCC but with no results, because it produced in shell output Library errors. And I also tried to paste those missing libraries yet achieve very little.


Solution

  • You could download some GCC cross-compiler. For example, if your PC is running some Debian-like Linux distribution -perhaps Ubuntu- you might install some gcc-7-arm-linux-gnueabi or similar (gcc-7-arm-linux-gnueabihf ...) package.

    The SDK for your board is likely to provide some cross-GCC & cross-binutils.

    You could build some cross binutils then some GCC cross-compiler from their source code (this is a bit more tricky).

    Your cross-compiler would compile (for ARM) on your Linux-running PC, not on your ARM circuit board.