Modify

Opened 5 years ago

Closed 4 years ago

Last modified 4 years ago

#13288 closed defect (obsolete)

OpenWRT backfire 10.03.1 does not compile gcc on OpenSUSE 12.3 x86_64

Reported by: luizluca@… Owned by: developers
Priority: normal Milestone: Chaos Calmer 15.05
Component: toolchain Version: 10.03.1
Keywords: Cc:

Description

Hello,

backfire compilation failed at this point:

make[5]: Leaving directory `/home/luizluca/prog-local/openwrt/backfire/build_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/gcc-4.1.2-initial/gcc'
make[4]: Leaving directory `/home/luizluca/prog-local/openwrt/backfire/build_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/gcc-4.1.2-initial'
# XXX: glibc insists on linking against libgcc_eh
( cd /home/luizluca/prog-local/openwrt/backfire/staging_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/lib/gcc/i486-openwrt-linux-uclibc/4.1.2 ; [ -e libgcc_eh.a ] || ln -sf libgcc.a libgcc_eh.a ; cp libgcc.a libgcc_initial.a; )
cp: cannot stat 'libgcc.a': No such file or directory
make[3]: *** [/home/luizluca/prog-local/openwrt/backfire/staging_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/stamp/.gcc-initial_installed] Error 1
make[3]: Leaving directory `/home/luizluca/prog-local/openwrt/backfire/toolchain/gcc'
make[2]: *** [toolchain/gcc/compile] Error 2
make[2]: Leaving directory `/home/luizluca/prog-local/openwrt/backfire'
make[1]: *** [/home/luizluca/prog-local/openwrt/backfire/staging_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/stamp/.toolchain_install] Error 2
make[1]: Leaving directory `/home/luizluca/prog-local/openwrt/backfire'
make: ** [world] Erro 2

The problem is that libgcc.a is at .../backfire/staging_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/lib64/gcc/i486-openwrt-linux-uclibc/4.1.2 while the script expects it to be at ../backfire/staging_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/lib/gcc/i486-openwrt-linux-uclibc/4.1.2.

If I copy all contents of the lib64 directory to lib and retry, the compilations goes.

cp -r /home/luizluca/prog-local/openwrt/backfire/staging_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/lib64/gcc/i486-openwrt-linux-uclibc/4.1.2/* /home/luizluca/prog-local/openwrt/backfire/staging_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/lib/gcc/i486-openwrt-linux-uclibc/4.1.2/

I think that this is some side-effect of opensuse using lib64 as default libdir while debian uses lib. I guess the problem is that lib64 should never existed as all .o files inside it are 32bit files. An ugly hack would be to add a symblink from lib64 to lib.

FYI: thunk seems to have no problem with gcc. AA has some problem with grub before gcc that I'm trying to figure out.

Attachments (0)

Change History (8)

comment:1 Changed 5 years ago by luizluca@…

I double checked AA and AA and trunk does not have this problem.

comment:2 Changed 5 years ago by anonymous

The same problem affects uclib after gcc:

make[3]: Entering directory `/home/luizluca/prog-local/openwrt/backfire/build_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/uClibc-0.9.30.1'
install -d lib/
rm -f lib/ld-uClibc.so lib/ld-uClibc.so.0 lib/ld-uClibc-0.9.30.1.so
i486-openwrt-linux-uclibc-gcc -Wl,--sort-common -Wl,--sort-section,alignment -m32 -Wl,-shared -Wl,--warn-common -Wl,--warn-once -Wl,-z,combreloc -Wl,-z,relro -Wl,-z,defs   -Wl,-e,_start -Wl,-z,now -Wl,-Bsymbolic -Wl,--export-dynamic -Wl,--sort-common -Wl,--discard-locals -Wl,--discard-all -Wl,--no-undefined -Wl,-soname=ld-uClibc.so.0 -nostdlib -o lib/ld-uClibc-0.9.30.1.so  -Wl,--whole-archive ldso/ldso/ld-uClibc_so.a -Wl,--no-whole-archive  /home/luizluca/prog-local/openwrt/backfire/staging_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/lib64/gcc/i486-openwrt-linux-uclibc/4.1.2/libgcc_initial.a 
i486-openwrt-linux-uclibc-gcc: /home/luizluca/prog-local/openwrt/backfire/staging_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/lib64/gcc/i486-openwrt-linux-uclibc/4.1.2/libgcc_initial.a: No such file or directory
make[3]: *** [lib/ld-uClibc.so] Error 1
make[3]: Leaving directory `/home/luizluca/prog-local/openwrt/backfire/build_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/uClibc-0.9.30.1'
make[2]: *** [/home/luizluca/prog-local/openwrt/backfire/staging_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/stamp/.uclibc_installed] Error 2
make[1]: *** [toolchain/uClibc/compile] Error 2
make -r toolchain/install: build failed. Please re-run make with V=99 to see what's going on
make: ** [toolchain/install] Erro 1

But this time, I had to copy lib to lib64.

cp -r /home/luizluca/prog-local/openwrt/backfire/staging_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/lib/gcc/i486-openwrt-linux-uclibc/4.1.2/* /home/luizluca/prog-local/openwrt/backfire/staging_dir/toolchain-i386_gcc-4.1.2_uClibc-0.9.30.1/lib64/gcc/i486-openwrt-linux-uclibc/4.1.2/

comment:3 Changed 5 years ago by nbd

  • Resolution set to obsolete
  • Status changed from new to closed

comment:4 Changed 4 years ago by anonymous

I can reproduce this on my openSUSE 12.3 system. The logs are here: http://pastebin.com/FYyxXFHf

comment:5 Changed 4 years ago by anonymous

  • Resolution obsolete deleted
  • Status changed from closed to reopened

comment:6 Changed 4 years ago by anonymous

cp -r staging_dir/toolchain-mips_r2_gcc-4.3.3+cs_uClibc-0.9.30.1/lib64/gcc/mips-openwrt-linux-uclibc/4.3.3/* staging_dir/toolchain-mips_r2_gcc-4.3.3+cs_uClibc-0.9.30.1/lib/gcc/mips-openwrt-linux-uclibc/4.3.3/
cp -r staging_dir/toolchain-mips_r2_gcc-4.3.3+cs_uClibc-0.9.30.1/lib/gcc/mips-openwrt-linux-uclibc/4.3.3/* staging_dir/toolchain-mips_r2_gcc-4.3.3+cs_uClibc-0.9.30.1/lib64/gcc/mips-openwrt-linux-uclibc/4.3.3/

These commands works around problem (each needs to be executed after the error shows and then re-run make)

comment:7 Changed 4 years ago by nbd

  • Resolution set to obsolete
  • Status changed from reopened to closed

backfire is still obsolete and unmaintained. please do not reopen this ticket

comment:8 Changed 4 years ago by jow

  • Milestone changed from Backfire 10.03.2 to Chaos Calmer (trunk)

Milestone Backfire 10.03.2 deleted

Add Comment

Modify Ticket

Action
as closed .
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.