Hi, this failure happens on native and crosscompiling(so you can reproduce easily and quickly with this one). Steps to reproduce cross-compiling: crossdev -S sh4-unknown-linux-gnu emerge-wrapper --init emerge-sh4-unknown-linux-gnu glibc More easier steps: crossdev -S --l 2.9_p20081201-r2 sh4-unknown-linux-gnu I also found that not using -S on crossdev, works fine. The error is as follows, but i'll attach the build.log: > /var/tmp/cross/sh4-unknown-linux-gnu/portage/cross-sh4-unknown-linux-gnu/glibc-2.9_p20081201-r2/work/build-default-sh4-unknown-linux-gnu-nptl/elf/ld.so.lds sh4-unknown-linux-gnu-gcc -Wl,-O1 -nostdlib -nostartfiles -shared -o /var/tmp/cross/sh4-unknown-linux-gnu/portage/cross-sh4-unknown-linux-gnu/glibc-2.9_p20081201-r2/work/build-default-sh4-unknown-linux-gnu-nptl/elf/ld.so \ -Wl,-z,combreloc -Wl,-z,relro -Wl,--hash-style=both -Wl,-z,defs -Wl,-z,now \ /var/tmp/cross/sh4-unknown-linux-gnu/portage/cross-sh4-unknown-linux-gnu/glibc-2.9_p20081201-r2/work/build-default-sh4-unknown-linux-gnu-nptl/elf/librtld.os -Wl,--version-script=/var/tmp/cross/sh4-unknown-linux-gnu/portage/cross-sh4-unknown-linux-gnu/glibc-2.9_p20081201-r2/work/build-default-sh4-unknown-linux-gnu-nptl/ld.map \ -Wl,-soname=ld-linux.so.2 -T /var/tmp/cross/sh4-unknown-linux-gnu/portage/cross-sh4-unknown-linux-gnu/glibc-2.9_p20081201-r2/work/build-default-sh4-unknown-linux-gnu-nptl/elf/ld.so.lds /var/tmp/cross/sh4-unknown-linux-gnu/portage/cross-sh4-unknown-linux-gnu/glibc-2.9_p20081201-r2/work/build-default-sh4-unknown-linux-gnu-nptl/elf/librtld.os: In function `__udivmoddi4': divdi3.c:(.text+0x15d2c): undefined reference to `__udiv_qrnnd_16' divdi3.c:(.text+0x15ecc): undefined reference to `__udiv_qrnnd_16' divdi3.c:(.text+0x16024): undefined reference to `__udiv_qrnnd_16' collect2: ld returned 1 exit status make[2]: *** [/var/tmp/cross/sh4-unknown-linux-gnu/portage/cross-sh4-unknown-linux-gnu/glibc-2.9_p20081201-r2/work/build-default-sh4-unknown-linux-gnu-nptl/elf/ld.so] Error 1 make[2]: Leaving directory `/var/tmp/cross/sh4-unknown-linux-gnu/portage/cross-sh4-unknown-linux-gnu/glibc-2.9_p20081201-r2/work/glibc-2.9-20081201/elf' make[1]: *** [elf/subdir_lib] Error 2 make[1]: Leaving directory `/var/tmp/cross/sh4-unknown-linux-gnu/portage/cross-sh4-unknown-linux-gnu/glibc-2.9_p20081201-r2/work/glibc-2.9-20081201' make: *** [all] Error 2
you're saying it builds fine with gcc-4.3.3 but not gcc-3.4.6 ? i'm pretty sure the symbol __udiv_qrnnd_16 comes gcc, so i would say this isnt really a bug. we just need to update the gcc depend in glibc-2.9 for sh targets.
(In reply to comment #1) > you're saying it builds fine with gcc-4.3.3 but not gcc-3.4.6 ? i'm pretty > sure the symbol __udiv_qrnnd_16 comes gcc, so i would say this isnt really a > bug. we just need to update the gcc depend in glibc-2.9 for sh targets. > stable gcc is 4.1.2 :)
"crossdev -S --g 4.2.4-r1 --l 2.9_p20081201-r2 sh4-unknown-linux-gnu" works So yeah, guess raising the dep to gcc-4.2.4-r1 would work. Thats funny though, for having gcc-4.3.3 you need to have glibc-2.9, for which you need gcc-4.2.4! :D
Oh, i remember now, gcc-4.2.4-r1 is not keyworded on sh :P
i wasnt really planning on mucking with gcc-4.2 for sh. early versions of gcc-4.3 worked fine natively, but for some reason the latest ones segfault while compiling itself and i havent had a chance to figure out why. it seemed like the pie patches are causing the problem, but i reviewed them in detail and couldnt quite spot an error. oddly, cross-compiling gcc-4.3.3 works fine :/
Oh, i was wrong again :) gcc-4.3.3-r1 depends on >=glibc-2.8, glibc-2.8 builds fine with gcc-4.1.2. So, for getting gcc-4.3.3-r1 on a stable system, you need: -emerge =glibc-2.8* -emerge gcc Not sure what would be the workaround here or if it can even be fixed.
Ah, since you marked glibc-2.8 stable, guess this isn't an issue anymore, since stable users should have glibc-2.8 :) Feel free to close this then.
Closing, since you said so :)