Created attachment 514440 [details] log strobil-pc ~ # crossdev -S -t sh4 - * crossdev version: 20180105 * Host Portage ARCH: amd64 * Target Portage ARCH: sh * Target System: sh4-unknown-linux-gnu * Stage: 4 (C/C++ compiler) * ABIs: default * binutils: binutils-[stable] * gcc: gcc-[stable] * headers: linux-headers-[stable] * libc: glibc-[stable] * CROSSDEV_OVERLAY: /usr/local/portage-crossdev * PORT_LOGDIR: /var/log/portage * PORTAGE_CONFIGROOT: / * Portage flags: * leaving sys-devel/binutils in /usr/local/portage-crossdev * leaving sys-devel/gcc in /usr/local/portage-crossdev * leaving sys-kernel/linux-headers in /usr/local/portage-crossdev * leaving sys-devel/gdb in /usr/local/portage-crossdev * leaving metadata/layout.conf alone in /usr/local/portage-crossdev * Log: /var/log/portage/cross-sh4-unknown-linux-gnu-binutils.log * Emerging cross-binutils ... [ ok ] * Log: /var/log/portage/cross-sh4-unknown-linux-gnu-linux-headers-quick.log * Emerging cross-linux-headers-quick ... [ ok ] * Log: /var/log/portage/cross-sh4-unknown-linux-gnu-glibc-headers.log * Emerging cross-glibc-headers ... [ ok ] * Log: /var/log/portage/cross-sh4-unknown-linux-gnu-gcc-stage1.log * Emerging cross-gcc-stage1 ... [ ok ] * Log: /var/log/portage/cross-sh4-unknown-linux-gnu-linux-headers.log * Emerging cross-linux-headers ... [ ok ] * Log: /var/log/portage/cross-sh4-unknown-linux-gnu-glibc.log * Emerging cross-glibc ... * error: glibc failed :( * * If you file a bug, please attach the following logfiles: * /var/log/portage/cross-sh4-unknown-linux-gnu-info.log * /var/log/portage/cross-sh4-unknown-linux-gnu-glibc.log.xz * /var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc*/temp/glibc-config.logs.tar.xz
Created attachment 514442 [details] log2
Created attachment 514444 [details] log3
Created attachment 514446 [details] emerge-info.txt
Created attachment 514448 [details] build.log
Is it a complete build log? It does not see to have an error in the end. Just stops abruptly.
(In reply to Sergei Trofimovich from comment #5) > Is it a complete build log? It does not see to have an error in the end. > Just stops abruptly. Attached last build log
Created attachment 515146 [details] cross-sh4-unknown-linux-gnu-glibc.log.xz
mv -f /var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/build-default-sh4-unknown-linux-gnu-nptl/elf/rtld-libc.aT /var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/build-default-sh4-unknown-linux-gnu-nptl/elf/rtld-libc.a make[3]: Leaving directory '/var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/glibc-2.25/elf' sh4-unknown-linux-gnu-gcc -Wl,-O1 -Wl,--as-needed -Wl,-O1 -Wl,--as-needed -nostdlib -nostartfiles -r -o /var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/build-default-sh4-unknown-linux-gnu-nptl/elf/librtld.os '-Wl,-(' /var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/build-default-sh4-unknown-linux-gnu-nptl/elf/dl-allobjs.os /var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/build-default-sh4-unknown-linux-gnu-nptl/elf/rtld-libc.a -lgcc '-Wl,-)' \ -Wl,-Map,/var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/build-default-sh4-unknown-linux-gnu-nptl/elf/librtld.os.map sh4-unknown-linux-gnu-gcc -Wl,-O1 -Wl,--as-needed -Wl,-O1 -Wl,--as-needed -nostdlib -nostartfiles -shared -o /var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/build-default-sh4-unknown-linux-gnu-nptl/elf/ld.so.new \ -Wl,-z,combreloc -Wl,-z,relro -Wl,-z,defs -Wl,-z,now \ /var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/build-default-sh4-unknown-linux-gnu-nptl/elf/librtld.os -Wl,--version-script=/var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/build-default-sh4-unknown-linux-gnu-nptl/ld.map \ -Wl,-soname=ld-linux.so.2 \ -Wl,-defsym=_begin=0 /var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/build-default-sh4-unknown-linux-gnu-nptl/elf/librtld.os: In function `strcspn': (.text+0x1462c): undefined reference to `__strchrnul' collect2: error: ld returned 1 exit status make[2]: *** [Makefile:456: /var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/build-default-sh4-unknown-linux-gnu-nptl/elf/ld.so] Error 1 make[2]: Leaving directory '/var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/glibc-2.25/elf' make[1]: *** [Makefile:216: elf/subdir_lib] Error 2 make[1]: Leaving directory '/var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/glibc-2.25' make: *** [Makefile:9: all] Error 2 make: Leaving directory '/var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/build-default-sh4-unknown-linux-gnu-nptl' * ERROR: cross-sh4-unknown-linux-gnu/glibc-2.25-r9::crossdev failed (compile phase): * emake failed
(In reply to strobil from comment #8) > /var/tmp/portage/cross-sh4-unknown-linux-gnu/glibc-2.25-r9/work/build- > default-sh4-unknown-linux-gnu-nptl/elf/librtld.os: In function `strcspn': > (.text+0x1462c): undefined reference to `__strchrnul' > collect2: error: ld returned 1 exit status Interesting. I can't reproduce it locally. Looking at your glibc build log I see a few issues: - quite old binutils is used: """checking version of /usr/libexec/gcc/sh4-unknown-linux-gnu/as... 2.25.1, ok""" Consider switching to 2.29.1 via 'binutils-config sh4-unknown-linux-gnu-2.29.1'. - make sure you are using gcc-5.4.0 as sh4 cross-compiler and not something older via 'gcc-config sh4-unknown-linux-gnu-5.4.0'
Thank you! Switching to the last binutils and gcc helped for me!
Woohoo! Let's ignore older binutils then. Closing as OBSOLETE.