jahboater
Posts: 3051
Joined: Wed Feb 04, 2015 6:38 pm

GCC 8.2 released

Fri Jul 27, 2018 11:24 am

Bug fix release.

See script here to download, build, and optionally install it:

viewtopic.php?f=33&t=212636&p=1310910#p1310910

User avatar
The Traveler
Posts: 361
Joined: Sat Oct 21, 2017 3:48 pm

Re: GCC 8.2 released

Fri Jul 27, 2018 11:56 am

+1

Thanks for the heads up. :)
Retired IT professional, C programmer and "beardie weirdie".
RPi interests: Developing an Infinite Improbability Drive
“Thinking outside of the box allows you to get rewards outside of your reach.” Matshona Dhliwayo

lianergoist
Posts: 33
Joined: Sat Nov 08, 2014 12:38 pm
Location: Horsens, Denmark

Re: GCC 8.2 released

Sat Jul 28, 2018 8:48 am

Also +1 from me!

Maybe this is a stupid question, but why do we need the extra options to configure? Isn't it supposed to auto-detect that? Sure, things like --enable-languages=c,c++ makes sense, but the rest of it looks like it could/would/should be auto-detected.

I ask because I plan to install gdb. 'Show configuration' in gdb says:

Code: Select all

(gdb) show configuration
This GDB was configured as follows:
   configure --host=arm-linux-gnueabihf --target=arm-linux-gnueabihf
             --with-auto-load-dir=$debugdir:$datadir/auto-load
             --with-auto-load-safe-path=$debugdir:$datadir/auto-load
             --with-expat
             --with-gdb-datadir=/usr/share/gdb (relocatable)
             --with-jit-reader-dir=/usr/lib/gdb (relocatable)
             --without-libunwind-ia64
             --with-lzma
             --with-python=/usr (relocatable)
             --without-guile
             --with-separate-debug-dir=/usr/lib/debug (relocatable)
             --with-system-gdbinit=/etc/gdb/gdbinit
             --with-babeltrace

("Relocatable" means the directory can be moved with the GDB installation
tree, and GDB will still find it.)
(gdb)
So, should I pass these options to configure? Maybe other things I should include?

BTW - it takes 17+ hours for a rpi zero to compile the kernel... :-)
Thomas Jensen

There are two types of people.
1) Those who can extrapolate from incomplete data

jahboater
Posts: 3051
Joined: Wed Feb 04, 2015 6:38 pm

Re: GCC 8.2 released

Sat Jul 28, 2018 9:08 am

lianergoist wrote:
Sat Jul 28, 2018 8:48 am
Maybe this is a stupid question, but why do we need the extra options to configure? Isn't it supposed to auto-detect that? Sure, things like --enable-languages=c,c++ makes sense, but the rest of it looks like it could/would/should be auto-detected.
I'm not sure - they were needed some time ago, but maybe now that native works properly ...
It takes hours to build so I have not experimented. Maybe now is the time as it would be nice not to have to edit the script. For GCC, "gcc -v" shows the config.
lianergoist wrote:
Sat Jul 28, 2018 8:48 am
BTW - it takes 17+ hours for a rpi zero to compile the kernel... :-)
It takes around 50 hours to compile GCC on a Pi Zero :) which is why I cross compile it on a Pi3B+ (around 4.5 hours).
Just set the config for the Pi Zero, run the script - say no to the install question at the end of course.
Tar up the entire build tree (tar Jcf gcc.tar.xz gcc-8.2.0) then untar it on the Pi Zero, "cd gcc-8.2.0/obj" then "sudo make install".
The tar to xz takes ages though - gzip is probably better.

echmain
Posts: 79
Joined: Fri Mar 04, 2016 8:26 pm

Re: GCC 8.2 released

Sun Jul 29, 2018 3:04 am

lianergoist wrote:
Sat Jul 28, 2018 8:48 am
Also +1 from me!

Maybe this is a stupid question, but why do we need the extra options to configure? Isn't it supposed to auto-detect that? Sure, things like --enable-languages=c,c++ makes sense, but the rest of it looks like it could/would/should be auto-detected.
I tried doing the configure with only 2 options, languages (c,c++) and prefix(/usr/local/...) but the compile fails after about an hour (on the 3B+). I don’t remember the error exactly, but clearly some more stuff needs to be spcified.

Using Jahboater’s syntax works perfectly so I’m sticking with that.

AbhiTronix
Posts: 5
Joined: Sun Sep 02, 2018 3:04 pm

Re: GCC 8.2 released

Tue Sep 04, 2018 5:34 am

I also have created Latest Set of Precompiled Raspberry Pi GCC Cross-Compilers (Easiest Method) here:

https://github.com/abhiTronix/raspberry ... -compilers

5mins Build/Compile time, No more Compiling/Error Handing !!! Good luck :)

jahboater
Posts: 3051
Joined: Wed Feb 04, 2015 6:38 pm

Re: GCC 8.2 released

Tue Sep 04, 2018 6:22 am

Perhaps the examples for wget etc should have 8.2 in rather than 6.3 so people can just cut and paste them?
I assume installing 8.2 native is the most common usage by far. On the Pi, 6.3 comes pre-installed.

AbhiTronix
Posts: 5
Joined: Sun Sep 02, 2018 3:04 pm

Re: GCC 8.2 released

Tue Sep 04, 2018 4:24 pm

Perhaps the examples for wget etc should have 8.2 in rather than 6.3 so people can just cut and paste them?
Correct. Thanks for suggesting, I've updated readme. But be sure to check out that 6.3.0 binary is for cross-compiler only (not native) which means it is for Linux x64 machine(As Raspberrypi GCC Cross-Compiler) not for installing in raspberry pi. That's why I've highlighted the Binaries Description in the repo. which points out the use of each binary. Hope this will help. ;)

Return to “C/C++”