OpenWrt Forum Archive

Topic: Trying to build 12.09 and older

The content of this topic has been archived on 1 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

Hi everyone. It fails building even toolchain. Host OS: ubuntu 16.04, gcc 4.7-5.4
With 15.05.1 it's ok.

do someone have ideas? thanks in advance.

/home/user/attitude_adjustment/openwrt/build_dir/toolchain-mipsel_gcc-4.6-linaro_uClibc-0.9.33.2/gcc-linaro-4.6-2012.02/gcc/cp/except.c:341:7: note: in expansion of macro 'gcc_unreachable'
gcc_unreachable ();
^~~~~~~~~~~~~~~
In file included from /home/user/attitude_adjustment/openwrt/build_dir/toolchain-mipsel_gcc-4.6-linaro_uClibc-0.9.33.2/gcc-linaro-4.6-2012.02/gcc/cp/except.c:912:0:
cfns.gperf: At top level:
cfns.gperf:101:1: error: 'gnu_inline' attribute present on 'libc_name_p'
cfns.gperf:26:14: error: but not here
In file included from /home/user/attitude_adjustment/openwrt/build_dir/toolchain-mipsel_gcc-4.6-linaro_uClibc-0.9.33.2/gcc-linaro-4.6-2012.02/gcc/cp/except.c:27:0:
/home/user/attitude_adjustment/openwrt/build_dir/toolchain-mipsel_gcc-4.6-linaro_uClibc-0.9.33.2/gcc-linaro-4.6-2012.02/gcc/cp/except.c: In function 'nothrow_spec_p':
/home/user/attitude_adjustment/openwrt/build_dir/toolchain-mipsel_gcc-4.6-linaro_uClibc-0.9.33.2/gcc-linaro-4.6-2012.02/gcc/system.h:636:55: warning: ISO C does not support 'FUNCTION' predefined identifier -Wpedantic ? fancy_abort (FILE, LINE, FUNCTION), 0 : 0))
^
/home/user/attitude_adjustment/openwrt/build_dir/toolchain-mipsel_gcc-4.6-linaro_uClibc-0.9.33.2/gcc-linaro-4.6-2012.02/gcc/cp/except.c:1170:3: note: in expansion of macro 'gcc_assert'
gcc_assert (processing_template_decl
^~~~~~~~~~
/home/user/attitude_adjustment/openwrt/build_dir/toolchain-mipsel_gcc-4.6-linaro_uClibc-0.9.33.2/gcc-linaro-4.6-2012.02/gcc/cp/except.c: In function 'build_noexcept_spec':
/home/user/attitude_adjustment/openwrt/build_dir/toolchain-mipsel_gcc-4.6-linaro_uClibc-0.9.33.2/gcc-linaro-4.6-2012.02/gcc/system.h:636:55: warning: ISO C does not support 'FUNCTION' predefined identifier -Wpedantic ? fancy_abort (FILE, LINE, FUNCTION), 0 : 0))
^
/home/user/attitude_adjustment/openwrt/build_dir/toolchain-mipsel_gcc-4.6-linaro_uClibc-0.9.33.2/gcc-linaro-4.6-2012.02/gcc/cp/except.c:1222:7: note: in expansion of macro 'gcc_assert'
gcc_assert (processing_template_decl || expr == error_mark_node);

Sorry for that but the only thing I know is that: you need an older version of GCC to compile older versions of OpenWRT

magres wrote:

Hi everyone. It fails building even toolchain. Host OS: ubuntu 16.04, gcc 4.7-5.4

Like gerrydoro said, you need to use an older buildhost. Otherwise the native gcc used for building the toolchain will fail, just like you have noticed.

Use e.g. Ubuntu 12.04 without updates as the buildhost, if you want to build Openwrt 12.09

The discussion might have continued from here.