| Summary: | rpm-4.2.1 compilation failed | ||
|---|---|---|---|
| Product: | Gentoo Linux | Reporter: | Jackie Polke <jackie> |
| Component: | Current packages | Assignee: | Stefan Jones (RETIRED) <cretin> |
| Status: | RESOLVED DUPLICATE | ||
| Severity: | normal | CC: | arnvid, sandino |
| Priority: | High | ||
| Version: | unspecified | ||
| Hardware: | x86 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Package list: | Runtime testing required: | --- | |
|
Description
Jackie Polke
2004-05-21 14:41:56 UTC
So what happens when you "rm -rf /var/tmp/portage/rpm*" then try again? Same exact errors? I'm asking because I just merged rpm three times. The first two times I got errors, not even the same ones, and the last time I didn't get any errors. I haven't figured out what the problem is, though, since the ebuild doesn't use emake. I was able to build rpm after I emerged beecrypt. I got the same error - though I can reproduce it on every try. I tried rm -rf /var/tmp/portage/* - to no avail. I also tried reemerging beecrypt. I have even recompiled my whole world since the last try :) Portage 2.0.50-r9 (x86, gcc-3.3.4, glibc-2.3.3.20040420-r0, 2.6.7-hardened-r3) ================================================================= System uname: 2.6.7-hardened-r3 i686 AMD Duron(tm) Gentoo Base System version 1.5.1 Autoconf: sys-devel/autoconf-2.59-r4 Automake: sys-devel/automake-1.8.5-r1 ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CFLAGS="-march=athlon -mcpu=athlon -mmmx -m3dnow -O2 -pipe -fomit-frame-pointer -ffast-math -fforce-addr -falign-functions=4" CHOST="i686-pc-linux-gnu" COMPILER="" CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /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/bind /var/qmail/control" CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d" CXXFLAGS="-march=athlon -mcpu=athlon -mmmx -m3dnow -O2 -pipe -fomit-frame-pointer -ffast-math -fforce-addr -falign-functions=4" DISTDIR="/storage/portage/distfiles" FEATURES="autoaddcvs ccache sandbox sfperms strict" GENTOO_MIRRORS="http://ftp.easynet.nl/mirror/gentoo/ ftp://gentoo.inode.at/source/ http://gentoo.inode.at" MAKEOPTS="-j2" PKGDIR="/storage/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/usr/local/portage" SYNC="rsync://localhost/gentoo-portage" USE="3dnow acpi apache2 apm berkdb chroot crypt curl erandom exiscan-acl gd gdbm gif gmp gpm hardened hardenedphp imagemagick imap innodb java jpeg ldap libwww maildir mmx mysql nagios-dns nagios-ntp nagios-ping nagios-ssh ncurses nls nptl pam parse-clocks pcre pdflib perl pic pie png python readline samba sasl slang snmp socks5 sse ssl tcpd tetex threads tiff truetype usb vhosts wildlsearch x86 xml xml2 zlib" Okay, I think I tracked down the error. It's in lib/rpmrc.c, line 900 to line 902:
__asm__("cpuid"
: "=a" (*eax), "=b" (*ebx), "=c" (*ecx), "=d" (*edx)
: "a" (op));
This piece of assembler-code doesn't compile on a hardened gcc, and throws the following error:
rpmrc.c: In function `is_athlon':
rpmrc.c:900: error: can't find a register in class `BREG' while reloading `asm'
The commandline is:
gcc -DHAVE_CONFIG_H -I. -I. -I.. -I. -I.. -I../build -I../rpmdb -I../rpmio -I/usr/include/beecrypt -I../popt -I../zlib -march=athlon -mcpu=athlon -O2 -pipe -D_GNU_SOURCE -D_REENTRANT -Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes -Wno-char-subscripts -MT rpmrc.lo -MD -MP -MF .deps/rpmrc.Tpo -c rpmrc.c -o rpmrc.o
The file compiles fine when -fno-pie is added to the command.
I'm not sure if it's an upstream-bug or a problem with the hardened toolchain, maybe the hardened devs could have a look at this...
-fno-pie does not help gcc -DHAVE_CONFIG_H -I. -I. -I.. -I. -I.. -I../build -I../rpmdb -I../rpmio -I/usr/include/beecrypt -I../popt -I../zlib -march=athlon-xp -O3 -pipe -fprefetch-loop-arrays -fno-pie -D_GNU_SOURCE -D_REENTRANT -Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes -Wno-char-subscripts -MT rpmrc.lo -MD -MP -MF .deps/rpmrc.Tpo -c rpmrc.c -fPIC -DPIC -o .libs/rpmrc.lo rpmrc.c: In function `rpmPlatform': rpmrc.c:791: warning: implicit declaration of function `rpmioSlurp' Works fine here, I do not use hardened. Just a fully up to date unstable setup with nptl. Is this problem still there on normal non-hardened systems? If not I will reassign to the hardened team. I have the same problem with my non-hardnened server. Linux trance 2.6.7-gentoo-r14 #1 SMP Fri Aug 13 11:51:35 CEST 2004 i686 Intel(R) Xeon(TM) CPU 2.00GHz GenuineIntel GNU/Linux rpmrc.c: In function `rpmPlatform': rpmrc.c:791: warning: implicit declaration of function `rpmioSlurp' gcc -DHAVE_CONFIG_H -I. -I. -I.. -I. -I.. -I../build -I../rpmdb -I../rpmio -I/usr/include/beecrypt -I../popt -I../zlib -march=pentium4 -pipe -O2 -D_GNU_SOURCE -D_REENTRANT -Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes -Wno-char-subscripts -MT rpmrc.lo -MD -MP -MF .deps/rpmrc.Tpo -c rpmrc.c -o rpmrc.o >/dev/null 2>&1 make[3]: *** [rpmrc.lo] Error 1 make[3]: Leaving directory `/var/tmp/portage/rpm-4.2.1/work/rpm-4.2.1/lib' make[2]: *** [all] Error 2 make[2]: Leaving directory `/var/tmp/portage/rpm-4.2.1/work/rpm-4.2.1/lib' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/rpm-4.2.1/work/rpm-4.2.1' make: *** [all] Error 2 !!! ERROR: app-arch/rpm-4.2.1 failed. !!! Function src_compile, Line 46, Exitcode 2 !!! (no error message) Annoying. It compiles fine on my p3 box.. Just compiled it there. Ok, I cannot reproduce any errors here yet, wtill trying... I bet it is the asm code in rpmrc.c though. I think we have two errors here, the fail compile on non-hardeded systems and the hardened failure reported in #3 and #4. Will check for any updates to the file upstream. This must of been a transient toolchain error, closing as works for me. Please reopen if it still persists. Seems others have hit this problem again *** This bug has been marked as a duplicate of 69811 *** |