Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 28907 - sys-apps/module-init-tools-0.9.14 fails to compile
Summary: sys-apps/module-init-tools-0.9.14 fails to compile
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High critical (vote)
Assignee: Martin Schlemmer (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-09-16 13:12 UTC by Lisa Seelye (RETIRED)
Modified: 2003-09-24 19:00 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Lisa Seelye (RETIRED) gentoo-dev 2003-09-16 13:12:21 UTC
gcc -march=athlon -Os -pipe -I./../include -D_GNU_SOURCE  
-DCONFIG_ROOT_CHECK_OFF=0  -DELF_MACHINE_H='"elf_i386.h"' -DARCH_i386  -c -o 
sys_oim.o sys_oim.c
gcc -march=athlon -Os -pipe -I./../include -D_GNU_SOURCE  
-DCONFIG_ROOT_CHECK_OFF=0  -DELF_MACHINE_H='"elf_i386.h"' -DARCH_i386  -c -o 
xftw.o xftw.c
sys_oim.c: In function `old_sys_init_module':
sys_oim.c:36: error: can't find a register in class `BREG' while reloading `asm'
make[1]: *** [sys_oim.o] Error 1
make[1]: *** Waiting for unfinished jobs....
In file included from xftw.c:94:
../include/util.h:42: warning: built-in function `log' declared as non-function
In file included from config.c:64:
../include/util.h:42: warning: built-in function `log' declared as non-function
make[1]: Leaving directory `/var/tmp/portage/module-init-tools-0.9.
14/work/modutils-2.4.25/util'
make: *** [all] Error 2

!!! ERROR: sys-apps/module-init-tools-0.9.14 failed.
!!! Function src_compile, Line 73, Exitcode 2
!!! emake modutils failed



Portage 2.0.49-r4 (default-x86-1.4, gcc-3.3.1, glibc-2.3.2-r4, 2.4.
21-pfeifer-r1_pre4)
=================================================================
System uname: 2.4.21-pfeifer-r1_pre4 i686 AMD Athlon(tm) Processor
distcc 2.10 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
ccache version 2.2 [enabled]
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-march=athlon -Os -pipe"
CHOST="i686-pc-linux-gnu"
COMPILER="gcc3"
CONFIG_PROTECT="/etc /var/qmail/control /usr/kde/2/share/config 
/usr/kde/3/share/config /usr/X11R6/lib/X11/xkb /usr/kde/3.1/share/config 
/usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ 
/usr/share/config"
CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d"
CXXFLAGS="-march=athlon -Os -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="sandbox cvs ccache"
GENTOO_MIRRORS="ftp://mirror.iawnet.sandia.gov/pub/gentoo/ http://gentoo.noved.
org/ ftp://gentoo.noved.org/"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="cvs://lisa@cvs.gentoo.org:/home/cvsroot"
USE="x86 oss apm foomaticdb libg++ mad mikmod nls pdflib quicktime gtkhtml gdbm 
berkdb slang readline tetex bonobo guile sdl gpm libwww ssl python imlib motif 
-arts 3dnow aalib acl avi cdr crypt cups curl dga directfb doc dvd encode alsa 
-esd ethereal evo flash freetds gd gif gnome gphoto2 gtk ipv6 jpeg -kde -java 
lcms maildir mbox memlimit mmx mpeg -mozilla mysql ncurses oggvorbis opengl pam 
pda -pcmcia perl png qt samba sasl spell svga truetype tcpd tcltk X xml xml2 
xmms xv zlib ldap"
Comment 1 Wojciech Milkowski 2003-09-16 13:48:19 UTC
The same situation, but other error:

gcc  -march=athlon-xp -O3 -pipe -fomit-frame-pointer -Wunused -Wall -Wcast-align   -o depmod  depmod.o moduleops.o tables.o zlibsupport.o
gcc  -march=athlon-xp -O3 -pipe -fomit-frame-pointer -Wunused -Wall -Wcast-align   -o modinfo  modinfo.o zlibsupport.o
/usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.1/libgcc_eh.a(unwind-dw2-fde-glibc.o)(.text+0x1651): In function `_Unwind_Find_FDE':
/var/tmp/portage/gcc-3.3.1-r1/work/gcc-3.3.1/gcc/unwind-dw2-fde-glibc.c:283: undefined reference to `dl_iterate_phdr'
collect2: ld returned 1 exit status
make: *** [insmod.static] Error 1

Portage 2.0.49-r4 (default-x86-1.4, gcc-3.3.1, glibc-2.3.2-r4, 2.6.0-test5)
=================================================================
System uname: 2.6.0-test5 i686 AMD Athlon(tm) XP 3000+
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-march=athlon-xp -O3 -pipe -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
COMPILER="gcc3"
CONFIG_PROTECT="/etc /var/qmail/control /usr/share/config /usr/kde/2/share/config /usr/kde/3/share/config /usr/X11R6/lib/X11/xkb"
CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d"
CXXFLAGS="-march=athlon-xp -O3 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs sandbox ccache nostrip"
GENTOO_MIRRORS="http://trumpetti.atm.tut.fi/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 oss avi crypt cups encode foomaticdb gif jpeg libg++ libwww mad mikmod mpeg ncurses nls pdflib png quicktime spell truetype xml2 xmms xv zlib gdbm berkdb slang readline svga java X sdl gpm tcpd pam ssl perl python esd imlib oggvorbis gnome gtk motif opengl 3dnow sse mmx -apm -kde -qt acpi bonobo cdr dvd gtk2 tiff wmf jikes mozilla apache2 ipv6 alsa -arts cscope dga flash jack -tetex nptl"
Comment 2 Martin Schlemmer (RETIRED) gentoo-dev 2003-09-16 14:29:38 UTC
Lisa Marie: Try without -Os please.  Or maybe with -march=i686.

Wojciech Milkowski:  Known issue from 3.3.1 - supposed to be what -r2 also
                     should have fixed (did here actually =).  Should be
                     hacked not to compile static.
Comment 3 Lisa Seelye (RETIRED) gentoo-dev 2003-09-16 17:07:29 UTC
Fails without -Os too
Fails without -Os and while using -march=i686 -pipe
Comment 4 Andreas Simon 2003-09-17 01:46:30 UTC
I get the same error as in comment #1 when compiling with gcc-3.3.1-r1 but not with gcc-3.3.1-r2. 
Comment 5 Andreas Simon 2003-09-18 01:19:49 UTC
This problem applies to sys-apps/module-init-tools-0.9.15_pre1 as well. 
Comment 6 Laurence Jupp 2003-09-21 08:57:48 UTC
I get the errors in comment #1, but only when compiling using hardened-gcc. After

hardened-gcc -R

it compiles that bit fine. (This is with gcc 3.3.1-r1)
Comment 7 Stefan Jones (RETIRED) gentoo-dev 2003-09-21 09:05:56 UTC
An email I sent, only found this bug after I sent it!

Martin,

As I remember from http://gcc.gnu.org/ml/gcc/2003-08/msg00664.html
you had problems statically linking binaries with the new glibc.

I have since found a sort of quick fix, it is the following:

Edit the file:

/usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.1/specs

and in the last section:

*link_command:
%{!fsyntax-only:%{!c:%{!M:%{!MM:%{!E:%{!S:    %(linker) %l %{pie:-pie}
%X %{o*}
%{A} %{d} %{e*} %{m} %{N} %{n} %{r}    %{s} %{t} %{u*} %{x} %{z} %{Z}
%{!A:%{!nostdlib:%{!nostartfiles:%S}}}    %{static:-lc} %{L*}
%(link_libgcc) %o
%{!nostdlib:%{!nodefaultlibs:%(link_gcc_c_sequence)}}   
%{!A:%{!nostdlib:%{!nostartfiles:%E}}} %{T*} }}}}}}

edit it so it has "%{static:-lc}" not "%{static:}" as it normally has. (
for me anyway)

Now I can compile static binaries again without the undefined reference
errors ...

Stefan
Comment 8 Sami Nieminen 2003-09-22 10:23:31 UTC
Stefan's fix works for me also. 
Comment 9 Martin Schlemmer (RETIRED) gentoo-dev 2003-09-24 19:00:28 UTC
Stephan, yes, it does work.  Also work if you add '-lc' to the libgcc link
stuff (first directive for static linking).  I however do not like this,
so tried an alternative that would not always just stick libc in there
(and worked fine here, but failed for others badly).

Anyhow, -r3 should fix this (if you do not use propolice, as this could still
break static linking in some weird ways).