# emerge gnome -uv Calculating dependencies ...done! >>> emerge (1 of 46) dev-perl/SGMLSpm-1.03-r5 to / >>> md5 src_uri ;-) SGMLSpm-1.03ii.tar.gz >>> Unpacking source... >>> Unpacking SGMLSpm-1.03ii.tar.gz to /var/tmp/portage/SGMLSpm-1.03-r5/work >>> Source unpacked. if [ ! -d /var/tmp/portage/SGMLSpm-1.03-r5/image//usr/lib/perl5/site_perl/5.6.1/SGMLS ]; then\ mkdir /var/tmp/portage/SGMLSpm-1.03-r5/image//usr/lib/perl5/site_perl/5.6.1/SGMLS; \ chmod a+x /var/tmp/portage/SGMLSpm-1.03-r5/image//usr/lib/perl5/site_perl/5.6.1/SGMLS; \ fi sed -e 's!/usr/bin/perl!/usr/bin/perl!' sgmlspl.pl > /var/tmp/portage/SGMLSpm-1.03-r5/image//usr/bin/sgmlspl cp SGMLS.pm /var/tmp/portage/SGMLSpm-1.03-r5/image//usr/lib/perl5/SGMLS.pm /bin/sh: line 1: /var/tmp/portage/SGMLSpm-1.03-r5/image//usr/bin/sgmlspl: No such file or directory make: *** [/var/tmp/portage/SGMLSpm-1.03-r5/image//usr/bin/sgmlspl] Error 1 make: *** Waiting for unfinished jobs.... cp: cannot create regular file `/var/tmp/portage/SGMLSpm-1.03-r5/image//usr/lib/perl5/SGMLS.pm': No such file or directory make: *** [/var/tmp/portage/SGMLSpm-1.03-r5/image//usr/lib/perl5/SGMLS.pm] Error 1 mkdir: cannot create directory `/var/tmp/portage/SGMLSpm-1.03-r5/image//usr/lib/perl5/site_perl/5.6.1/SGMLS': No such file or directory chmod: cannot access `/var/tmp/portage/SGMLSpm-1.03-r5/image//usr/lib/perl5/site_perl/5.6.1/SGMLS': No such file or directory make: *** [/var/tmp/portage/SGMLSpm-1.03-r5/image//usr/lib/perl5/site_perl/5.6.1/SGMLS] Error 1 !!! ERROR: dev-perl/SGMLSpm-1.03-r5 failed. !!! Function src_compile, Line 479, Exitcode 2 !!! emake failed !!! If you need support, post the topmost build error, NOT this status message. # emerge info Portage 2.0.51_pre12 (default-x86-1.4, gcc-3.3.3, glibc-2.3.3.20040420-r0, 2.6.7-rc3-mm2) ================================================================= System uname: 2.6.7-rc3-mm2 i686 AMD Duron(tm) Processor Gentoo Base System version 1.4.16 distcc 2.13 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [enabled] Autoconf: sys-devel/autoconf-2.59-r4 Automake: sys-devel/automake-1.8.5-r1 Binutils: sys-devel/binutils-2.14.90.0.8-r1 ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CFLAGS="-march=athlon-tbird -O3 -pipe -fomit-frame-pointer" CHOST="i686-pc-linux-gnu" COMPILER="gcc3" CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config /usr/kde/3.2/share/config /usr/kde/3.3/share/config /usr/kde/3/share/config /usr/lib/mozilla/defaults/pref /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/X11/Sessions /etc/X11/xdm /etc/X11/xinit /etc/X11/xkb /etc/X11/xserver /etc/X11/xsm /etc/env.d /etc/gconf /etc/init.d /etc/terminfo /etc/env.d" CXXFLAGS="-march=athlon-tbird -O3 -pipe -fomit-frame-pointer" DISTDIR="/usr/portage/distfiles" FEATURES="autoaddcvs ccache distcc prelink sandbox" GENTOO_MIRRORS="http://gentoo.inode.at/ http://www.mirror.ac.uk/sites/www.ibiblio.org/gentoo/" MAKEOPTS="-j3" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/usr/local/portage" SYNC="rsync://rsync.nl.gentoo.org/gentoo-portage" USE="3dnow S3TC X aalib acl acpi alsa apache2 arts artswrappersuid avantgo avi berkdb bluetooth bonobo cdr crypt cups curl dga dvd encode esd exiscan-acl f77 fbcon flash foomaticdb gd gdbm ggi gif gnome gphoto2 gpm gps gstreamer gtk gtk2 gtkhtml guile imap imlib innodb java javascript jpeg kde ldap libg++ libwww mad mbox mmx mozilla mpeg mysql nas ncurses nls offensive oggvorbis opengl opie oss pam pda pdflib perl png postgres python qt quicktime readline samba scanner sdl slang snmp spell ssl svga tcltk tcpd tetex tiff truetype usb vhosts wmf x86 xinerama xml xml2 xmms xv zlib"
Created attachment 34376 [details, diff] Patch for SGMLSpm-1.03-r5.ebuild I've had the same issue. The problem is, that the standard src_compile, which is invoked since there is none in the ebuild, executes make, before it is modified by the sed scripts in the ebuild. The attached patch fixes it for now by moving the manipulation of the make file into src_unpack and modifying the make target "all" to do nothing, because otherwise it would still be executed by src_compile before the appropriate directories are created. However, after looking into that, I think, the ebuild should be completely reworked: * Design the Makefile to fit specifically for Gentoo. * Get rid of these ugly and error-prone sed scripts and give the parameters to the Makefile by environment variables.
Thanks for the patch, I applied it. I agree that it should be fixed differently. The problem with so many seds in portage is that they aren't being error checked properly. I think the problem will need to be fixed globally in portage eventually.
Can we get 1.03-r5 marked stable on x86? 1.03-r4 which is the current stable version fails to compile with the same issues as listed in this bug.