crossdev --b 2.16.1-r3 --g 4.1.1 --k 2.6.11-r5 --l 2.4-r3 --target i586-pc-linux-gnu -s4 fails with the following errors (from /var/log/portage/cross-i586-pc-linux-gnu-gcc-stage2.log) * Applying gcc-4.1.0-cross-compile.patch ... [ ok ] >>> Source unpacked. >>> Compiling source in /var/tmp/cross/i586-pc-linux-gnu/portage/gcc-4.1.1/work/gcc-4.1.1 ... * CFLAGS="-O2 -pipe" * CXXFLAGS="" * Configuring gcc ... * running gcc-compiler-configure * configuring for GCC_LANG: c,c++,fortran !!! ERROR: cross-i586-pc-linux-gnu/gcc-4.1.1 failed. Call stack: ebuild.sh, line 1546: Called dyn_compile ebuild.sh, line 937: Called src_compile ebuild.sh, line 1255: Called toolchain_src_compile toolchain.eclass, line 24: Called gcc_src_compile toolchain.eclass, line 1520: Called gcc_do_configure toolchain.eclass, line 1269: Called built_with_use 'cross-i586-pc-linux-gnu/glibc' 'crosscompile_opts_headers-only' eutils.eclass, line 1605: Called die !!! cross-i586-pc-linux-gnu/glibc-2.4-r3 does not actually support the crosscompile_opts_headers-only USE flag! !!! If you need support, post the topmost build error, and the call stack if relevant. !!! This ebuild is from an overlay: '/root/portage' ... done! Here's the relevant cross-i586-pc-linux-gnu-info.log: ------------------------------------------------------------------------------------------------------------------------------------ * Host Portage ARCH: x86 * Target Portage ARCH: x86 * Target System: i586-pc-linux-gnu * Stage: 4 (C/C++ compiler) * binutils: binutils-2.16.1-r3 * gcc: gcc-4.1.1 * headers: linux-headers-2.6.11-r5 * libc: glibc-2.4-r3 * PORTDIR_OVERLAY: /root/portage * PORT_LOGDIR: /var/log/portage * PKGDIR: /usr/portage/packages/cross/i586-pc-linux-gnu * PORTAGE_TMPDIR: /var/tmp/cross/i586-pc-linux-gnu _ - ~ - _ - ~ - _ - ~ - _ - ~ - _ - ~ - _ - ~ - _ - ~ - _ - ~ - _ - ~ - _ - ~ - _ - ~ - Gentoo Base System version 1.12.4 Portage 2.1.1 (default-linux/x86/2006.0, gcc-4.1.1, glibc-2.4-r3, 2.6.17-gentoo-r7 i686) ================================================================= System uname: 2.6.17-gentoo-r7 i686 Intel(R) Pentium(R) III Mobile CPU 1133MHz Last Sync: Mon, 11 Sep 2006 07:20:01 +0000 distcc 2.18.3 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled] app-admin/eselect-compiler: [Not Present] dev-lang/python: 2.4.3-r1 dev-python/pycrypto: 2.0.1-r5 dev-util/ccache: [Not Present] dev-util/confcache: [Not Present] sys-apps/sandbox: 1.2.17 sys-devel/autoconf: 2.13, 2.59-r7 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2 sys-devel/binutils: 2.16.1-r3 sys-devel/gcc-config: 1.3.13-r3 sys-devel/libtool: 1.5.22 virtual/os-headers: 2.6.11-r5 ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CBUILD="i686-pc-linux-gnu" CFLAGS="-O2 -march=pentium3 -fomit-frame-pointer" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/lib/mozilla/defaults/pref /usr/share/X11/xkb" CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/terminfo" CXXFLAGS="-O2 -march=pentium3 -fomit-frame-pointer" DISTDIR="/usr/portage/distfiles" FEATURES="autoconfig distlocks metadata-transfer sandbox sfperms strict" GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo" LANG="en_GB.UTF-8" LC_ALL="en_GB.UTF-8" LINGUAS="en_GB" PKGDIR="/usr/portage/packages/cross/i586-pc-linux-gnu" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude='/distfiles' --exclude='/local' --exclude='/packages'" PORTAGE_TMPDIR="/var/tmp/cross/i586-pc-linux-gnu" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/root/portage" SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage" USE="x86 X aac alsa apache2 apm asf avi berkdb bitmap-fonts bluetooth cli crypt cups dhcp dlloader dri dvd dvdread elibc_glibc embos s encode exif foomaticdb fortran fuse gcj gdbm gif gimpprint glut glx gpg2-experimental gpm gstreamer gtk gtk2 imlib input_devices_k eyboard input_devices_mouse ipv6 isdnlog java jpeg kernel_linux lcms libg++ libwww linguas_en_GB mad mbox mikmod milter mmx mmxext m otif mp3 mpeg mppe-mppc ncurses nls nptl nptlonly nsplugin nvidia offensive ogg opengl oss pam pcre pdflib perl png ppds pppd python qt3 qt4 quicktime readline real reflection sasl sdk sdl session spell spl sse sse2 ssl tcpd tiff timidity truetype truetype-fonts t ype1-fonts udev unicode usb userland_GNU utf8 video_cards_nv video_cards_nvidia video_cards_vesa vorbis win32codecs xface xinerama x ml xmms xorg xv zlib" Unset: CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LDFLAGS, MAKEOPTS, PORTAGE_RSYNC_EXTRA_OPTS
What does that mean? Is there a fix for this?
I've a workaround (not a patch) first crossdev with -s3: #crossdev -s3 --b 2.16.1-r3 --g 4.1.1 --k 2.6.11-r5 --l 2.4-r3 --target then force toolchain.eclass do not check 'crosscompile_opts_headers-only' (1270): --elif built_with_use ${CATEGORY}/${needed_libc} crosscompile_opts_headers-only --; then ++else confgcc="${confgcc} --disable-shared --with-sysroot=${PREFIX}/${CTARGET}" --else -- confgcc="${confgcc} --with-sysroot=${PREFIX}/${CTARGET}" fi and crossdev stage 4: #crossdev -s4 --b 2.16.1-r3 --g 4.1.1 --k 2.6.11-r5 --l 2.4-r3 --target make sure to unfix toolchain.eclass before emerging another package using toolchain (undo modif or emerge --sync)
Yep, that definitely works; it's now building stage2. Will report back on progress.
should be fixed in cvs