When emerge is almost finished ld fails because __guard and __stack_smash_handler are missing. I do not use "hardened". "emerge -a -v xorg-x11" says: x11-base/xorg-x11-6.8.0-r4 ... -hardened Reproducible: Always Steps to Reproduce: 1. build glibc without Gentoo-additions 2. emerge xorg-x11 Actual Results: [ebuild U ] x11-base/xorg-x11-6.8.0-r4 [6.7.0-r1] -3dfx +3dnow* +bitmap-fonts* -cjk -debug -dlloader -dmx +doc* +font-server* -hardened -insecure-drivers +ipv6* -minimal -mmx +nls +opengl +pam -sdk -sse -static +truetype-fonts* +type1-fonts* (-uclibc) -xprint +xv 0 kB [cut ...] gcc -o Xorg -O2 -march=i686 -fomit-frame-pointer -fno-strict-aliasing -ansi -pedantic -Wno-return-type -w -L../../exports/lib xkb/xf86KillSrv.o xkb/xf86VT.o xkb/xf86Private.o ../../programs/Xserver/hw/xfree86/common/xf86Init.o ../../programs/Xserver/hw/xfree86/common/xf86IniExt.o ../../programs/Xserver/hw/xfree86/common/libxf86.a ../../programs/Xserver/hw/xfree86/parser/libxf86config.a ../../programs/Xserver/hw/xfree86/os-support/libxf86_os.a ../../programs/Xserver/hw/xfree86/loader/libloader.a ../../programs/Xserver/hw/xfree86/common/libxf86.a dix/libdix.a os/libos.a ../../exports/lib/libXau.a ../../lib/font/fontbase.o ../../lib/font/libfontbase.a Xext/libexts.a xkb/libxkb.a Xi/libxinput.a lbx/liblbx.a ../../lib/lbxutil/liblbxutil.a ../../programs/Xserver/hw/xfree86/common/libxf86.a composite/libcomposite.a damageext/libdamage.a miext/damage/libdamage.a xfixes/libxfixes.a miext/cw/libcw.a Xext/libexts.a xkb/libxkb.a Xi/libxinput.a lbx/liblbx.a ../../lib/lbxutil/liblbxutil.a randr/librandr.a render/librender.a dix/libxpstubs.a mi/libmi.a composite/libcomposite.a damageext/libdamage.a miext/damage/libdamage.a xfixes/libxfixes.a miext/cw/libcw.a Xext/libexts.a xkb/libxkb.a Xi/libxinput.a lbx/liblbx.a ../../lib/lbxutil/liblbxutil.a randr/librandr.a render/librender.a ../../programs/Xserver/hw/xfree86/os-support/libxf86_os.a -lz -lm -lpam -rdynamic -ldl -lpam_misc -lXau -lXdmcp -lXau -rdynamic -ldl -Wl,-rpath-link,../../exports/lib ../../programs/Xserver/hw/xfree86/loader/libloader.a(xf86sym.o)(.data+0x124c): undefined reference to `__stack_smash_handler' ../../programs/Xserver/hw/xfree86/loader/libloader.a(xf86sym.o)(.data+0x1254): undefined reference to `__guard' collect2: ld returned 1 exit status [...etc] Expected Results: Just building or a warning saying YOU CANNOT DO THIS! When I build without the .ebuild system xorg-x11 compiles without error. Ebuild file has hardcoded support for stack-protection. At least a warning should occur when emerging without "hardened" USE flag. Maybe this is just cosmetics? I can, after all, install from true source and add the package name to /etc/portage/profiles/package.provided (or "inject"). EMERGE INFO: #emerge info Portage 2.0.51-r15 (default-linux/x86/2004.3, gcc-3.3.4, glibc-2.3.3.20041008-r0, 2.4.28ax2-tun i686) ================================================================= System uname: 2.4.28ax2-tun i686 AMD Duron(tm) Gentoo Base System version 1.4.16 Python: dev-lang/python-2.3.3-r1 [2.3.3 (#1, Aug 29 2004, 02:50:23)] dev-lang/python: 2.3.3-r1 sys-devel/autoconf: 2.59-r4 sys-devel/automake: 1.8.5-r1 sys-devel/binutils: 2.14.90.0.8-r1 sys-devel/libtool: 1.4.3-r4 virtual/os-headers: 2.4.21-r1 ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CFLAGS="-O2 -march=i686 -fomit-frame-pointer" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /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/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=i686 -fomit-frame-pointer" DISTDIR="/usr/portage/distfiles" FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms" GENTOO_MIRRORS="ftp://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/ ftp://mirrors.sec.informatik.tu-darmstadt.de/gentoo/ http://ftp.du.se/pub/os/gentoo http://ds.thn.htu.se/linux/gentoo" LC_ALL="" MAKEOPTS="-j1" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/usr/local/portage" SYNC="rsync://rsync.skumleren.net/gentoo-portage" USE="x86 3dnow 3dnowex X Xaw3d alsa apm arts avi berkdb bitmap-fonts bonobo cdr crypt cups doc encode esd f77 fam flac font-server foomaticdb fortran gdbm gif gphoto2 gpm gtk2 gtkhtml guile imagemagick imlib ipv6 jpeg kde libg++ libgda libwww mad mikmod mmx2 motif mozplaintext mpeg mplayer ncurses network nls odbc oggvorbis opengl oss pam pdflib perl png postgres python qt quicktime readline real rtc samba sdl slang snmp spell ssl svga tcltk tcpd tetex tiff truetype truetype-fonts type1-fonts v4l v4l2 xine xinerama xml xml2 xmms xv xvid xvmc zlib" Unset: ASFLAGS, CBUILD, CTARGET, LANG, LDFLAGS
Advice on dealing with this?
Donald, does it work if you change roughly line 850, which reads: echo "#define ProPoliceSupport YES" >> ${HOSTCONF} to read: echo "#define ProPoliceSupport NO" >> ${HOSTCONF}
Do we have any glibc's around that are not patched still? I would highly recommend an upgrade of libc in addition to what donnie pointed out.
It sounds as if he's using a custom libc and expecting it to work seamlessly with our packaging.
glibc-2.3.3.20041008-r0 is the version that his emerge info says. This version should have the symbols. So maybe your right.. if such is the case then NOTABUG
A custom glibc which is not hardened (that is, without Propolice) will not work with xorg-x11-6.8.0-r4.ebuild You must make a custom xorg-x11 if you use a custom glibc. One way to do so is to change the xorg-x11-6.8.0-r4.ebuild file the following way: Around line 933, change the line which reads: echo "#define ProPoliceSupport YES" >> ${HOSTCONF} to read: echo "#define ProPoliceSupport NO" >> ${HOSTCONF} This solves the issue.