I'm guessing that linking fails because it does not include "-lexpat"; re-emerging expat-1.95.8 didn't help. Unfortunately, I can't compare the 3.1.4-r4 ebuild to 3.1.4-r3 (which worked) because the latter has been removed from the portage tree. Output from "emerge -u gawk": [snip] x86_64-pc-linux-gnu-gcc -march=athlon64 -O3 -pipe -fomit-frame-pointer -export-dynamic -o gawk array.o awkgram.o builtin.o dfa.o ext.o field.o gawkmisc.o getopt.o getopt1.o io.o main.o msg.o node.o random.o re.o regex.o replace.o version.o eval.o profile.o -ldl -lm x86_64-pc-linux-gnu-gcc -march=athlon64 -O3 -pipe -fomit-frame-pointer -export-dynamic -o pgawk array.o awkgram.o builtin.o dfa.o ext.o field.o gawkmisc.o getopt.o getopt1.o io.o main.o msg.o node.o random.o re.o regex.o replace.o version.o eval_p.o profile_p.o -ldl -lm io.o(.text+0x1d1): In function `iop_close': : undefined reference to `XML_PullerFree' io.o(.text+0x1da1): In function `iop_alloc': : undefined reference to `XML_PullerCreate' io.o(.text+0x1dbe): In function `iop_alloc': : undefined reference to `XML_PullerEnable' io.o(.text+0x2cf3): In function `get_a_record': : undefined reference to `XML_PullerNext' main.o(.text+0xfb6): In function `main': : undefined reference to `XML_ExpatVersion' collect2: ld returned 1 exit status make[2]: *** [gawk] Error 1 make[2]: *** Waiting for unfinished jobs.... io.o(.text+0x1d1): In function `iop_close': : undefined reference to `XML_PullerFree' io.o(.text+0x1da1): In function `iop_alloc': : undefined reference to `XML_PullerCreate' io.o(.text+0x1dbe): In function `iop_alloc': : undefined reference to `XML_PullerEnable' io.o(.text+0x2cf3): In function `get_a_record': : undefined reference to `XML_PullerNext' main.o(.text+0xfb6): In function `main': : undefined reference to `XML_ExpatVersion' collect2: ld returned 1 exit status make[2]: *** [pgawk] Error 1 make[2]: Leaving directory `/var/tmp/portage/gawk-3.1.4-r4/work/xmlgawk' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/gawk-3.1.4-r4/work/xmlgawk' make: *** [all] Error 2 !!! ERROR: sys-apps/gawk-3.1.4-r4 failed. !!! Function src_compile, Line 57, Exitcode 2 !!! xmlgawk make failed !!! If you need support, post the topmost build error, NOT this status message. "emerge info" output: Portage 2.0.51-r15 (default-linux/amd64/2004.3, gcc-3.4.3, glibc-2.3.4.20050125-r0, 2.6.10-gentoo-r7 x86_64) ================================================================= System uname: 2.6.10-gentoo-r7 x86_64 AMD Athlon(tm) 64 Processor 3500+ Gentoo Base System version 1.6.9 Python: dev-lang/python-2.3.5 [2.3.5 (#1, Feb 18 2005, 20:10:11)] dev-lang/python: 2.3.5 sys-devel/autoconf: 2.13, 2.59-r6 sys-devel/automake: 1.8.5-r3, 1.5, 1.7.9-r1, 1.6.3, 1.4_p6, 1.9.4 sys-devel/binutils: 2.15.92.0.2-r2 sys-devel/libtool: 1.5.10-r4 virtual/os-headers: 2.6.8.1-r3 ACCEPT_KEYWORDS="amd64 ~amd64" AUTOCLEAN="yes" CFLAGS="-march=athlon64 -O3 -pipe -fomit-frame-pointer" CHOST="x86_64-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 /var/qmail/control" CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d" CXXFLAGS="-march=athlon64 -O3 -pipe -fomit-frame-pointer" DISTDIR="/usr/portage/distfiles" FEATURES="autoaddcvs autoconfig ccache distlocks sandbox" GENTOO_MIRRORS="ftp://mirror.pacific.net.au/linux/Gentoo ftp://mirror.isp.net.au/pub/gentoo/" LANG="en_AU" LC_ALL="en_AU" MAKEOPTS="-j2" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" SYNC="rsync://rsync.au.gentoo.org/gentoo-portage" USE="amd64 X Xaw3d aalib acpi adns alsa apache2 arts audiofile authdaemond avi berkdb bidi bitmap-fonts blas bzlib cddb cdparanoia cdr chroot crypt cscope cupscurl divx4linux djbfft dmx dv dvd dvdr encode esd f77 faac faad fam fbcon flac font-server foomaticdb fortran fpx freetype gd gdbm gif gimpprint gpm gps graphviz gtk gtk2 imagemagick imap imlib jack java jbig jp2 jpeg jpeg2k junit kde lapack lcms libcaca lm_sensors lzw lzw-tiff mad maildir mikmod mmap mng motif mozdevelop mpeg mpi multilib ncurses nls nptl nvidia offensive oggvorbis openal openglpam pcre pda perl pic png povray ppds python qt quicktime readline sdk sdl slang sndfile spamassassin speex spell ssl svg tcltk tcpd theora tiff truetype truetype-fonts type1-fonts usb userlocales virus-scan wmf xine xml xml2 xmms xpm xprint xrandr xscreensaver xv yv12 zlib" Unset: ASFLAGS, CBUILD, CTARGET, LDFLAGS, PORTDIR_OVERLAY
confirmed - same bug here
Created attachment 51620 [details] Full build log confirmed. Bug is also present on ~x86. Portage 2.0.51-r15 (default-linux/x86/2004.3, gcc-3.4.3, glibc-2.3.4.20050125-r0, 2.6.11-rc3-nitro0 i686) ================================================================= System uname: 2.6.11-rc3-nitro0 i686 AMD Athlon(tm) XP 2500+ Gentoo Base System version 1.6.9 Python: dev-lang/python-2.3.5 [2.3.5 (#1, Feb 18 2005, 00:46:55)] distcc 2.18.3 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled] dev-lang/python: 2.3.5 sys-devel/autoconf: 2.13, 2.59-r6 sys-devel/automake: 1.4_p6, 1.7.9-r1, 1.8.5-r3, 1.6.3, 1.9.4, 1.5 sys-devel/binutils: 2.15.92.0.2-r2 sys-devel/libtool: 1.5.10-r4 virtual/os-headers: 2.6.8.1-r2 ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CFLAGS="-march=athlon-xp -O3 -pipe -fomit-frame-pointer -mmmx -msse -m3dnow -mfpmath=sse,387 -ffast-math" 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/lib/fax /usr/share/config /var/qmail/alias /var/qmail/control /var/spool/fax/etc" CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d" CXXFLAGS="-march=athlon-xp -O3 -pipe -fomit-frame-pointer -mmmx -msse -m3dnow -mfpmath=sse,387 -ffast-math" DISTDIR="/usr/portage/distfiles" FEATURES="autoaddcvs autoconfig ccache distlocks parallel-fetch sandbox sfperms" GENTOO_MIRRORS="http://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/ ftp://gd.tuwien.ac.at/opsys/linux/gentoo/ ftp://ftp.snt.utwente.nl/pub/os/linux/gentoo" LANG="nl_NL@euro" LC_ALL="nl_NL@euro" MAKEOPTS="-j5" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/usr/local/portage" SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage" USE="x86 3dnow X aalib alsa apache2 apm arts audiofile avi bash-completion bitmap-fonts bzlib calender cdparanoia cdr chroot crypt cups curl dba divx4linux dvd dvdr dvdread emboss encode esd f77 fam filepro flac font-server foomaticdb fortran gd gdbm gif gnome gphoto2 gpm gstreamer gtk gtk2 guile hal imagemagick imlib insecure-drivers java jpeg jpeg2k junit kde ldap libg++ libwww live mad mikmod mime mmx motif mpeg mplayer msn mysql ncurses network nls nptl nvidia odbc offensive oggvorbis ooo-kde opengl pam pdflib perl php pic png postgres python qmail qt quicktime readline real rplay samba scanner sdk sdl session sftplogging slang softmmu speex spell sse ssl stroke svga tcltk tcpd threads tiff truetype truetype-fonts type1-fonts usb userlocales v4l wmf xine xinerama xml xml2 xmms xprint xscreensaver xv xvid zlib video_cards_nvidia linguas_nl" Unset: ASFLAGS, CBUILD, CTARGET, LDFLAGS
I have the same bug too.
the problem is that autotools gets re-run for some reason in the xmlgawk subdir on your machines and the -lexpat is lost
Changing hardware to All since I'm getting this on x86.
Same here, x86 (pentium3) with selinux. ----------------------------- if i386-pc-linux-gnu-gcc -DDEFPATH="\".:/usr/share/awk\"" -DHAVE_CONFIG_H -DGAWK -DLOCALEDIR="\"/usr/share/locale\"" -I. -I. -I. -Iintl -O2 -march=pentium3 -fomit-frame-pointer -fforce-addr -MT awkgram.o -MD -MP -MF ".deps/awkgram.Tpo" -c -o awkgram.o awkgram.c; \ then mv -f ".deps/awkgram.Tpo" ".deps/awkgram.Po"; else rm -f ".deps/awkgram.Tpo"; exit 1; fi awkgram.y: In function `variable': awkgram.y:3041: warning: assignment makes pointer from integer without a cast i386-pc-linux-gnu-gcc -O2 -march=pentium3 -fomit-frame-pointer -fforce-addr -export-dynamic -o gawk array.o awkgram.o builtin.o dfa.o ext.o field.o gawkmisc.o getopt.o getopt1.o io.o main.o msg.o node.o random.o re.o regex.o replace.o version.o eval.o profile.o -ldl -lm i386-pc-linux-gnu-gcc -O2 -march=pentium3 -fomit-frame-pointer -fforce-addr -export-dynamic -o pgawk array.o awkgram.o builtin.o dfa.o ext.o field.o gawkmisc.o getopt.o getopt1.o io.o main.o msg.o node.o random.o re.o regex.o replace.o version.o eval_p.o profile_p.o -ldl -lm io.o(.text+0x296): In function `iop_close': : undefined reference to `XML_PullerFree' io.o(.text+0x276c): In function `iop_alloc': : undefined reference to `XML_PullerCreate' io.o(.text+0x2791): In function `iop_alloc': : undefined reference to `XML_PullerEnable' io.o(.text+0x39b0): In function `get_a_record': : undefined reference to `XML_PullerNext' main.o(.text+0x163d): In function `.L166': : undefined reference to `XML_ExpatVersion' collect2: ld returned 1 exit status make[2]: *** [gawk] Error 1 make[2]: *** Waiting for unfinished jobs.... io.o(.text+0x296): In function `iop_close': : undefined reference to `XML_PullerFree' io.o(.text+0x276c): In function `iop_alloc': : undefined reference to `XML_PullerCreate' io.o(.text+0x2791): In function `iop_alloc': : undefined reference to `XML_PullerEnable' io.o(.text+0x39b0): In function `get_a_record': : undefined reference to `XML_PullerNext' main.o(.text+0x163d): In function `.L166': : undefined reference to `XML_ExpatVersion' collect2: ld returned 1 exit status make[2]: *** [pgawk] Error 1 make[2]: Leaving directory `/var/tmp/portage/gawk-3.1.4-r4/work/xmlgawk' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/gawk-3.1.4-r4/work/xmlgawk' make: *** [all] Error 2 !!! ERROR: sys-apps/gawk-3.1.4-r4 failed. !!! Function src_compile, Line 57, Exitcode 2 ---------------------- Portage 2.0.51-r15 (selinux/2004.1/x86, gcc-3.4.3, glibc-2.3.4.20050125-r0, 2.6.7-hardened-r18 i686) ================================================================= System uname: 2.6.7-hardened-r18 i686 Pentium III (Coppermine) Gentoo Base System version 1.6.9 Python: dev-lang/python-2.3.5 [2.3.5 (#1, Feb 20 2005, 13:28:54)] dev-lang/python: 2.3.5 sys-devel/autoconf: 2.13, 2.59-r6 sys-devel/automake: 1.9.4, 1.5, 1.4_p6, 1.6.3, 1.7.9-r1, 1.8.5-r3 sys-devel/binutils: 2.15.92.0.2-r2 sys-devel/libtool: 1.5.10-r4 virtual/os-headers: 2.4.22-r1 ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CFLAGS="-O2 -march=pentium3 -fomit-frame-pointer -fforce-addr" CHOST="i386-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/config /var/bind /var/qmail/alias /var/qmail/control /var/vpopmail/domains /var/vpopmail/etc" CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d" CXXFLAGS="-O2 -march=pentium3 -fomit-frame-pointer -fforce-addr" DISTDIR="/usr/portage/distfiles" FEATURES="autoaddcvs autoconfig ccache distlocks fixpackages loadpolicy nostrip sandbox sfperms strict" GENTOO_MIRRORS="ftp://ftp.ussg.iu.edu/pub/linux/gentoo http://mirror.isp.net.au/pub/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="apache2 bash-completion berkdb cpdflib crypt cups curl dba debug dvd exif fam ftp gd gdbm hardened hardenedphp imap innodb ipv6 jabber jpeg ldap mad maildir mcal mhash mmx mysql ncurses nls oggvorbis pam pcntl pcre perl pic pie png postgres python readline samba selinux session simplexml slang snmp sockets spell sqlite ssl tcpd tidy tiff tokenizer truetype usb vhosts wddx x86 xml xml2 xmlrpc zaptel zlib" Unset: ASFLAGS, CBUILD, CTARGET, LANG, LC_ALL, LDFLAGS
Has anyone had this problem on a ~x86 or an ~arch systems this seems to be more an issue with a dep missing or not being completely fullfilled rather then anything else from what I have seen on the forums and here everyone is using some form of a stable release system no ~arch specific have been reported unless I have missed something.
scratch my last report me is blind as a bat tonight aight I have two simple things everyone that has had a fail report any packages of xml that are installed on your system, I do believe it will come down to XML-Parser being out of date or just out right missing.
I'm using ~x86 and have the same error everyone else is having. I do have XML-Parser 2.34 installed. From the emerge output, the details in the bug 57857 and the ebuild, I'm convinced that the ebuild is simply not telling the linker to link with expat. If you notice in the src_compile() the econf line for the first and second compilation are almost the same. From bug 81793 we are told that the first compilation doesn't use XML, whilst the second does. Therefore, either the EPATCH_OPTS in the src_unpack(), the patch itself or the ebuild lines are disabling or simply not enabling the link with expat.
what version of expat you have installed sorry just trying to help narrow this down seeing it installed fine for me no problems what so ever out of it.
I'm using XML-Parser version 2.34, and expat version 1.95.8. Gentoo ~x86 Linux val 2.6.10-morph21 #1 Sun Feb 6 19:48:23 UTC 2005 i686 AMD Athlon(tm) 64 Processor 3200+ AuthenticAMD GNU/Linux
I have expat 1.95.8. I've just noticed that in my case the XML patch is not being applied to the /var/tmp/portage/gawk-3.1.4-r4/work/xmlgawk dir. Perhaps the origin of the problem is that I simply don't have the patch* file in /usr/portage/sys-apps/gawk/files. I've also confirmed that the patch is available at the SRC_URI and have thus donwloaded and am re-emerging again.
I've just finished re-emerging gawk-3.4.1-r4 after the download of the patch and the problem persists. However, I've manually applied the patch in /var/tmp/portage/gawk-3.1.4-r4/work/xmlgawk/ and have run make. When I applied the patch, I discovered that the Makefile.in and awk.h files had not been patched. This led to make run without producing errors.
Alright I am gonna list some things I have found the culprit threw some forums anyone with gentoolkit installed please run "qpkg -I -nc -v automake" You should get something similar to this: sys-devel/automake-1.5 sys-devel/automake-1.6.3 sys-devel/automake-1.7.9-r1 sys-devel/automake-1.4_p6 sys-devel/automake-wrapper-1-r1 sys-devel/automake-1.9.4 sys-devel/automake-1.8.5-r3 If you do have all that installed show autoconf using "qpkg -I -nc -v autoconf" this will produce a list of: sys-devel/autoconf-2.13 sys-devel/autoconf-2.59-r6 sys-devel/autoconf-wrapper-2-r1 I have also setup a test enviroment to duplicate this error your getting it has yet to show up. I will post a log in a min of emerge gawk using version 3.1.4-r4 that you can all use to compare or send to me via email and I will compare.
The result of qpkg -I -nc -v automake sys-devel/automake-1.7.9-r1 sys-devel/automake-1.8.5-r3 sys-devel/automake-1.5 sys-devel/automake-wrapper-1-r1 sys-devel/automake-1.4_p6 sys-devel/automake-1.6.3 sys-devel/automake-1.9.4 The result of qpkg -I -nc -v autoconf sys-devel/autoconf-wrapper-2-r1 sys-devel/autoconf-2.59-r6 sys-devel/autoconf-2.13
Created attachment 51635 [details] Sucessful build of gawk 3.1.4-r4 You can compare this to yours if anyone is on an athlon-xp setup please post CFLAGS. After looking at other log I see alot of use flags that are not need and actually can break packages.
Alright finally able to duplicate this bug I will be working on this give me 20 mins or so and I will have a patch ready to correct the issue.
You don't have the xml USE flag. That's why the emerge doesn't break!! Remember that the gawk ebuild will compile gawk twice for those with the xml USE flag: the first one without support for XML, the second one with the support. In my case and I think all others, the first build is successful, it's the second that is broken.
Running ~x86 here. # qpkg -I -nc -v automake sys-devel/automake-1.7.9-r1 sys-devel/automake-1.8.5-r3 sys-devel/automake-1.5 sys-devel/automake-wrapper-1-r1 sys-devel/automake-1.4_p6 sys-devel/automake-1.6.3 sys-devel/automake-1.9.4 # qpkg -I -nc -v autoconf sys-devel/autoconf-wrapper-2-r1 sys-devel/autoconf-2.59-r6 sys-devel/autoconf-2.13 Installed as well: dev-perl/XML-Parser-2.34 and dev-libs/expat-1.95.8
I've just confirmed that as I've stated in the previous post, only those using the xml USE flag will have a broken gawk build. Those not using the xml USE flag will have no problem in emerging gawk.
Confirmed, turning off the xml use flag allows it to build.
The original bug report was that *xmlgawk* failed to build, not the vanilla gawk. Turning off the "xml" USE flag doesn't fix this - it just hides the problem.
Paul, your comment is absolutely correct and I completely agree with you. I've just clarified that it only matters when gawk is built using the xml USE flag - xmlgawk. As you can read from the posts on the bug, the discussion was being centred on gawk and not xmlgawk. Furthermore, for all those not interested in having xml support on gawk, disabling the xml USE flag is a quick fix.
Fair enough - I was concerned that people were spending time looking for a (non-existent) bug with gawk itself; I hadn't considered the need for a quick fix.
Created attachment 51638 [details] diff of new -r4 ebuild against working -r3 ebuild Having the same problem with emerge of xmlawk on athlon-xp ~x86 USE=xml. Here is the diff of the new -r4 ebuild (1st file) against the working -r3 ebuild if thats of any help
even forcing -lexpat does not solve the problem. There are no XML_Puller* symbols in libexpat.so
xml-puller.c is not in base_sources (Makefile.am), so it is not compiled and not there at link time.
Created attachment 51640 [details, diff] a patch against xmlgawk which solved the problem for me I could succeed after patching xmlgawk/Makefile.am and xmlgawk/awklib/Makefile.am. In awklib, make removes the eg subdirectory and then try to use some files from it. I feel my solution is somewhat weird, but it made things work for me (needs also some editing in gawk-3.1.4-r4.ebuild). Sorry for the noise if this does not help.
the eg diezctory problem was a make -j2 side effect.
These changes worked for me: (in src_compile() ) if use xml ; then cd "${SXML}" sed -e '/regex.h/a xml_puller.c \\\ xml_puller.h \\' -i Makefile.am econf LDFLAGS=-lexpat $(use_enable nls) || die emake -j 1 || die "xmlgawk make failed" fi They are allmost equivalent to the patch by Jean Br
These changes worked for me: (in src_compile() ) if use xml ; then cd "${SXML}" sed -e '/regex.h/a xml_puller.c \\\ xml_puller.h \\' -i Makefile.am econf LDFLAGS=-lexpat $(use_enable nls) || die emake -j 1 || die "xmlgawk make failed" fi They are allmost equivalent to the patch by Jean Bréfort
Has anybody confirmed that the xml patch that is supposed to be applied and says it is, actually doesnt apply and that may be the problem. Can anyone else check the patch contents and what it is supposed to change in some files and see if it did indeed change the files.
Ignore my stupid comment. I was checking wrong dir. duh
someone with this bug please run: `USE=xml MAKEOPTS=-d emerge gawk >& log` and then post the log as an attachment
Created attachment 51765 [details] Bzipped log as requested Same problem for me, log as requested above.
edit the ebuild and change the 'cp -r' in the src_unpack() to 'cp -a' and see if that fixes things
FREEDOM! sorry, success i meant :) that s/-r/-a replacement worked :)
fixed in cvs then
#35 solution from SpanKY helped me, too.
SpanKY solution works for me.
*** Bug 82795 has been marked as a duplicate of this bug. ***