Where is GCC compiler?


Could you please teach me about Linaro GCC compiler.

Linaro GCC compiler link is broken on Linaro Linux latest page.

Its comment is forrowing.
Page not found: /14.11/components/toolchain/binaries/aarch64-linux-gnu/gcc-linaro-4.9-2014.11-x86_64_aarch64-linux-gnu.tar.xz

May I use following link?

Thank you!

How did you find the broken link? That compiler is very old and we move these into our archives to discourage new users from following stale links to old releases.

You are certainly welcome to use the 4.9-2017.01 release but this is a v4.9 based release and is really for people, for some reason, cannot migrate to a recent version of GCC. The most recent version, linked to from the official Linaro download page is 6.3-2017.02.

Hi @danielt

thank you for quick reply.

How did you find the broken link? That compiler is very old and we move these into our archives1 to discourage new users from following stale links to old releases.

I looked its in Linaro Linux latest release notes for DragonBoard410c.

(Now,16.09 release notes)

“the Linaro GCC cross compiler” in the following sentence corresponds to its broken.

The DragonBoard 410c is an ARMv8 platform, and the kernel is compiled for the Aarch64 target. Even though it is possible to build natively, on the target board, It is recommended to build the Linux kernel on a PC development host. In which case you need to install a cross compiler for the ARM architecture. It is recommended to download the Linaro GCC cross compiler.

Hey @anon91830841

I think the broken link might be one for you! The link in your release
notes is broken (and before it was broken it was directing people to a
very old version of the compiler).

The most durable link for the toolchain is http://linaro.org/downloads
would probably be alright as well.

ouch… sure, i will fix the link for the next release! thanks for reporting it!

I have GCC 6.3 on my dragonboard (linaro kernel 4.9). How do I upgrade the GCC to version 7.2?

Simplest way is to install the 18.01 release (which has a v4.14 kernel):

I can’t (don’t want) to change the kernel. I already flashed kernel of 4.9.
I just need to upgrade the GCC from 6.3 to 7.2.

How can I do it?

Well I guess you could look at one of the following (these are ordered in accending order or risk-of-breaking-your-userspace-and-having-to-reinstall):

  • Cross-compile a native compiler from your PC. This is essentially free of risk and fairly fast but is extremely tricky for people without experience building compilers to get it right, and tutorials and blog posts are few and far between here.
  • Compile it yourself on DB410C. Also free of risk and instructions to build from source will be in the compiler documentation. This will be very slow and you might need to enable swap on the DB410C in order to have enough space to complete the build.
  • Take the compiler packages from buster whilst remaining on the stretch release. You will have to learn a lot about apt preferences in order to do this: https://wiki.debian.org/AptPreferences .
  • Perform a dist-upgrade (to take the current install from stretch to buster). You will end up with a consistent set of packages… but might break things in the process.

To be clear I’m not recommending any of the above… but if you don’t want to switch to a supported release its what you are left with.

Actually I missed one:

  • Use LXC to create a buster container inside your existing stretch userspace and use that for builds.

If I change the kernel to 4.14 instead of 4.9, I will be able to install gcc 7.2 using apt-get ?


I’m afraid the kernel version is more or less irrelavant for gcc.

What matters is what version of the rootfs image are you running. If you install 18.01, which uses Debian testing (“buster”) then you will already have gcc 7.2, if you stick to what you currently have (<= 17.09) based on Debian 9 (“stretch”) then you will have to try one of the tricks above.