~ sudo crossdev -s4 --portage --verbose --target avr - * crossdev version: 20190311 * Host Portage ARCH: amd64 * Target Portage ARCH: * * Target System: avr * Stage: 4 (C/C++ compiler) * USE=multilib: yes * ABIs: default * binutils: binutils-[latest] * gcc: gcc-[latest] * libc: avr-libc-[latest] * CROSSDEV_OVERLAY: /usr/local/portage * PORT_LOGDIR: /var/tmp/portage/log * PORTAGE_CONFIGROOT: / * Portage flags: --verbose * leaving sys-devel/binutils in /usr/local/portage * leaving sys-devel/gcc in /usr/local/portage * leaving dev-embedded/avr-libc in /usr/local/portage * leaving sys-devel/gdb in /usr/local/portage * leaving metadata/layout.conf alone in /usr/local/portage * Log: /var/tmp/portage/log/cross-avr-binutils.log * Emerging cross-binutils ... [ ok ] * Log: /var/tmp/portage/log/cross-avr-gcc-stage1.log * Emerging cross-gcc-stage1 ... * error: gcc failed :( * * If you file a bug, please attach the following logfiles: * /var/tmp/portage/log/cross-avr-info.log * /var/tmp/portage/log/cross-avr-gcc-stage1.log.xz * /var/tmp/portage/cross-avr/gcc*/temp/gcc-config.logs.tar.xz
Created attachment 577738 [details] cross-avr-info.log
Created attachment 577740 [details] cross-avr-gcc-stage1.log.xz
Created attachment 577742 [details] gcc-config.logs.tar.xz
> /var/tmp/portage/cross-avr/gcc-9.1.0/work/build/./gcc/as: line 106: exec: -m: invalid option > exec: usage: exec [-cl] [-a name] [command [arguments ...]] [redirection ...] Make sure you have cross-binutils selected and active. Simple test: $ LANG=C avr-as --version GNU assembler (Gentoo 2.32 p2) 2.32.0 $ binutils-config -l | fgrep avr [8] avr-2.32 *
`binutils-config avr-2.32` fixed that issue, and then avr-libc ran into a similar issue that was fixed with `gcc-config avr-9.1.0`, so immediate problem solved I guess. Should crossdev be running these commands automatically before it moves on to the next step? It seems odd that it isn't.
Normally emerging new gcc target switches compiler on. Probably we have some corner case like uninstall old version/install new version that leaves stale symlinks. Do you happen to remember what was the sequence if actions for you? The following: $ qlop -lu | fgrep cross-avr command might shed some light.
Let's close it as obsolete as there is no follow-up.