dev-libs/DirectFB-0.9.21 compile fails every time into the same error message --------------- generic_mmx.h: In function `Sop_argb_Sto_Dacc_MMX': generic_mmx.h:165: error: can't find a register in class `GENERAL_REGS' while reloading `asm' ------------------ emerge info output follows. The result is the same with 2.4 or 2.6 kernel headers. I doubt I need DirectFB for anything, but it prevents emerge -u world from proceeding. Reproducible: Always Steps to Reproduce: 1. VIDEO_CARDS='nvidia' emerge -u DirectFB 2. Just wait Actual Results: compile fails Expected Results: compile succeeds and produces someting useful tupajumi jarno # emerge info creating libdirectfb_display.la (cd .libs && rm -f libdirectfb_display.la && ln -s ../libdirectfb_display.la libdirectfb_display.la) make[3]: Leaving directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21/src/display' Making all in gfx make[3]: Entering directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21/src/gfx' Making all in generic make[4]: Entering directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21/src/gfx/generic' /bin/sh ../../../libtool --mode=compile i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../.. -I../../../include -I../../../lib -I../../../lib -I../../../src -D_REENTRANT -I/usr/include/libmpeg3 -fomit-frame-pointer -Wall -O3 -ffast-math -pipe -O2 -march=pentium2 -pipe -momit-leaf-frame-pointer -fno-pie -D_GNU_SOURCE -Werror-implicit-function-declaration -c generic.c mkdir .libs i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../.. -I../../../include -I../../../lib -I../../../lib -I../../../src -D_REENTRANT -I/usr/include/libmpeg3 -fomit-frame-pointer -Wall -O3 -ffast-math -pipe -O2 -march=pentium2 -pipe -momit-leaf-frame-pointer -fno-pie -D_GNU_SOURCE -Werror-implicit-function-declaration -c generic.c -fPIC -DPIC -o .libs/generic.o In file included from generic.c:4910: generic_mmx.h: In function `Sop_argb_Sto_Dacc_MMX': generic_mmx.h:165: error: can't find a register in class `GENERAL_REGS' while reloading `asm' make[4]: *** [generic.lo] Error 1 make[4]: Leaving directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21/src/gfx/generic' make[3]: *** [all-recursive] Error 1 make[3]: Leaving directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21/src/gfx' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21/src' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21' make: *** [all-recursive-am] Error 2 !!! ERROR: dev-libs/DirectFB-0.9.21 failed. !!! Function src_compile, Line 87, Exitcode 2 !!! (no error message) !!! If you need support, post the topmost build error, NOT this status message. Portage 2.0.51-r15 (hardened/x86/2.6, gcc-3.3.5, glibc-2.3.4.20040808-r1, 2.6.10-hardened-r3 i686) ================================================================= System uname: 2.6.10-hardened-r3 i686 Pentium II (Deschutes) Gentoo Base System version 1.4.16 Python: dev-lang/python-2.2.3-r5,dev-lang/python-2.3.4-r1 [2.3.4 (#1, Feb 13 2005, 13:05:10)] dev-lang/python: 2.2.3-r5, 2.3.4-r1 sys-devel/autoconf: 2.13, 2.59-r6 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.4 sys-devel/binutils: 2.15.92.0.2-r1 sys-devel/libtool: 1.5.10-r4 virtual/os-headers: 2.4.22-r1, 2.6.5 ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CFLAGS="-O2 -march=pentium2 -pipe -momit-leaf-frame-pointer -fno-pie" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.3/env /usr/kde/3.3/share/config /usr/kde/3.3/shutdown /usr/kde/3/share/config /usr/lib/X11/xkb /usr/share/config /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/qmail/control" CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d" CXXFLAGS="-O2 -march=pentium2 -pipe -momit-leaf-frame-pointer -fno-pie" DISTDIR="/usr/portage/distfiles" FEATURES="autoaddcvs autoconfig ccache distlocks sandbox" GENTOO_MIRRORS="ftp://trumpetti.atm.tut.fi/gentoo/ ftp://ftp.linux.ee/pub/gentoo/distfiles/ ftp://ftp.uninett.no/pub/linux/Gentoo ftp://ftp.du.se/pub/os/gentoo http://ftp.du.se/pub/os/gentoo http://ftp.rhnet.is/pub/gentoo/ ftp://ftp.rhnet.is/pub/gentoo/ http://ftp.easynet.nl/mirror/gentoo/ ftp://ftp.easynet.nl/mirror/gentoo/ http://gentoo.blueyonder.co.uk" MAKEOPTS="-j2" PKGDIR="/usr/portage//packages/x86/" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage/" PORTDIR_OVERLAY="" SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage" USE="X aalib acl alsa apm arts avi berkdb cdparanoia cdr crypt cups curl dga directfb divx4linux dlloader dvb dvd dvdr emacs encode esd fam fbcon flac flash gb gd gdbm ggi ghoto2 gif gpm gtk gtk2 gtkhtml guile hardened hardenedphp imagemagick imap imlib innodb java jikes jpeg junit kde lcms libg++ libgda libwww mad maildir matroska mikmod mmx motif mozilla mpeg mule mysql ncurses nls odbc oggvorbis opengl pam pdflib perl pic pie plotutils pngprelude python qt qtmt quicktime readline sdl spell sse ssl svga tcltk tcpd tetex theora tiff truetype usb wmf x86 xine xml xml2 xmms xv xvid zlib" Unset: ASFLAGS, CBUILD, CTARGET, LANG, LC_ALL, LDFLAGS tupajumi jarno # creating libdirectfb_display.la sh: creating: command not found tupajumi jarno # (cd .libs && rm -f libdirectfb_display.la && ln -s ../libdirectfb_display.la libdirectfb_display.la) sh: cd: .libs: No such file or directory tupajumi jarno # make[3]: Leaving directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21/src/display' > Making all in gfx > make[3]: Entering directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21/src/gfx' > Making all in generic > make[4]: Entering directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21/src/gfx/generic' sh: command substitution: line 1: unexpected EOF while looking for matching `'' sh: command substitution: line 4: syntax error: unexpected end of file sh: make[3]:: command not found tupajumi jarno # /bin/sh ../../../libtool --mode=compile i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../.. -I../../../include -I../../../lib -I../../../lib -I../../../src -D_REENTRANT -I/usr/include/libmpeg3 -fomit-frame-pointer -Wall -O3 -ffast-math -pipe -O2-march=pentium2 -pipe -momit-leaf-frame-pointer -fno-pie -D_GNU_SOURCE -Werror-implicit-function-declaration -c generic.c ../../../libtool: ../../../libtool: No such file or directory tupajumi jarno # mkdir .libs tupajumi jarno # i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../.. -I../../../include -I../../../lib -I../../../lib -I../../../src -D_REENTRANT -I/usr/include/libmpeg3 -fomit-frame-pointer -Wall -O3 -ffast-math -pipe -O2 -march=pentium2 -pipe -momit-leaf-frame-pointer -fno-pie -D_GNU_SOURCE -Werror-implicit-function-declaration -c generic.c -fPIC -DPIC -o .libs/generic.o i686-pc-linux-gnu-gcc: generic.c: No such file or directory i686-pc-linux-gnu-gcc: no input files tupajumi jarno # In file included from generic.c:4910: sh: In: command not found tupajumi jarno # generic_mmx.h: In function `Sop_argb_Sto_Dacc_MMX': > generic_mmx.h:165: error: can't find a register in class `GENERAL_REGS' while reloading `asm' sh: Sop_argb_Sto_Dacc_MMX: generic_mmx.h:165: error: cant: command not found sh: generic_mmx.h:: command not found tupajumi jarno # make[4]: *** [generic.lo] Error 1 sh: make[4]:: command not found tupajumi jarno # make[4]: Leaving directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21/src/gfx/generic' > make[3]: *** [all-recursive] Error 1 > make[3]: Leaving directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21/src/gfx' > make[2]: *** [all-recursive] Error 1 > make[2]: Leaving directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21/src' sh: command substitution: line 1: unexpected EOF while looking for matching `'' sh: command substitution: line 4: syntax error: unexpected end of file sh: make[4]:: command not found tupajumi jarno # make[1]: *** [all-recursive] Error 1 sh: make[1]:: command not found tupajumi jarno # make[1]: Leaving directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21' > make: *** [all-recursive-am] Error 2 > > !!! ERROR: dev-libs/DirectFB-0.9.21 failed. make[1]: Leaving directory `/var/tmp/portage/DirectFB-0.9.21/work/DirectFB-0.9.21' make: *** [all-recursive-am] Error 2 ! ERROR: dev-libs/DirectFB-0.9.21 failed. > !!! Function src_compile, Line 87, Exitcode 2 > !!! (no error message) > !!! If you need support, post the topmost build error, NOT this status message. >
This is a compiler bug, gcc simply runs out of registers. Workarounds in order - removing "mmx" from USE flags during emerging this - Play around with the CFLAGS, e.g. changing -O2 to -O1 has worked somewhere else - Change gcc version
Removing mmx USE flag "solved" this problem for me. Thanks Roland!