Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 48377 - QA/Ebuild Violations: dev-lang/gpc
Summary: QA/Ebuild Violations: dev-lang/gpc
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Unspecified (show other bugs)
Hardware: All All
: High normal (vote)
Assignee: George Shapovalov (RETIRED)
URL:
Whiteboard:
Keywords:
: 23560 44712 48408 (view as bug list)
Depends on:
Blocks:
 
Reported: 2004-04-19 12:01 UTC by Nicholas Jones (RETIRED)
Modified: 2004-06-14 19:09 UTC (History)
5 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 Nicholas Jones (RETIRED) gentoo-dev 2004-04-19 12:01:52 UTC
QA Notice: gcc in global scope: dev-lang/gpc-20030209
Comment 1 Mr. Bones. (RETIRED) gentoo-dev 2004-04-19 18:01:03 UTC
*** Bug 48408 has been marked as a duplicate of this bug. ***
Comment 2 Aron Griffis (RETIRED) gentoo-dev 2004-06-06 16:07:19 UTC
gpc has such issues that it should be either fixed within a week or removed from portage.

GCC_PV=$(gcc -dumpversion)
SRC_URI="ftp://gcc.gnu.org/pub/gcc/releases/gcc-${GCC_PV}/gcc-${GCC_PV}.tar.bz2"

   You can't do this.  It breaks the portage cache.

There's no checking of any operations in the ebuild except econf and make.  No verification that any sed, mv, etc. is successful.

cd ${D}/usr/lib/gcc-lib/i686-pc-linux-gnu/

   You can't assume you're in i686.  Somebody has even marked this ebuild for sparc!

SAVEP="${P}"
unset P

   This is against the rules.  You should either sed or patch the Makefiles so they use a different variable from $(P).  Frankly, I'm not even sure it's necessary since the Makefile sets P = (blank).  Since the environment doesn't override the Makefile, there should be no need to clear P from the environment.
Comment 3 Aron Griffis (RETIRED) gentoo-dev 2004-06-06 17:02:55 UTC
Btw, the SRC_URI trick means that the digest is always broken, so this package can't even be merged unless the user regenerates the digest.
Comment 4 George Shapovalov (RETIRED) gentoo-dev 2004-06-06 19:07:02 UTC
Ugh, yea, that package is problemmatic, but is also a (looks like very) low use. I was putting it off for the more important packages, but you are right, this can drag on forever. 
I'll try to see within this week if I can "resurrect"  it (it was a bit of a moving target at the time, plus it was hard to find a version matching the "gcc of the moment", although this should be better now, with gcc somewhat stabilized). If I won't get a simple fix I'll mask and then remove it. Sadly, I am not sure if (if happens) this will even be noticed by anybody but the QA team :).

Oh, and BTW, I believe that SRC_URI is there since before we had a caching implemented and the corresponding policy up (yea, that really was ages ago).

George
Comment 5 Aron Griffis (RETIRED) gentoo-dev 2004-06-06 19:53:04 UTC
Thanks for looking at this, George.
Comment 6 George Shapovalov (RETIRED) gentoo-dev 2004-06-11 18:14:08 UTC
Dropping a note, that I am looking at this. The ebuild was based largerly on the gcc ebuild, but that one changed a lot since the gpc one was produced, so looks like it will take some time to adapt it. Nonetheless I'll try to resurrect it (new beta version came out just recently, so looks like this project is moving along)..
On the QA stuff:
#1 is gone,
#2 is in src_install and should be gone as I get there. I am stuck with src_compile now :).
#3 should probably go away too. Didn't get that far yet either..

George
Comment 7 George Shapovalov (RETIRED) gentoo-dev 2004-06-11 18:18:05 UTC
*** Bug 23560 has been marked as a duplicate of this bug. ***
Comment 8 George Shapovalov (RETIRED) gentoo-dev 2004-06-11 18:19:28 UTC
*** Bug 44712 has been marked as a duplicate of this bug. ***
Comment 9 George Shapovalov (RETIRED) gentoo-dev 2004-06-12 18:05:35 UTC
Ok, looks like I managed to make it work. New version in portage, removed 2.1, still want to keep that intermediary one for a bit longer..
All mentioned issued are resolved, although now it depends on a hardwired version of gcc, which may inconvenience end-user. Unfortunately I don't see an easy way around this without breaking server-side portage cache. Somehow I doubt I'll hear complaints about that :), so I'll let it stay the way it is for now..
Oh, and it is marked ~amd64 in addition (to ~x86 and ~sparc).

George
Comment 10 Derk W te Bokkel 2004-06-14 14:07:27 UTC
Gee, thanks fellows .. Great timing I needed this badly .. to match gcc 3.3.3 for some cross platform work ..

Derk
Comment 11 Derk W te Bokkel 2004-06-14 14:21:54 UTC
unfortunately it died on me during the compile on three similar machines at the same place ..

cd ./p/rts && \
CC="`echo /mnt/bigdisk1/tmp/portage/gpc-20040516/work/build/gcc/xgcc -B/mnt/bigdisk1/tmp/portage/gpc-20
040516/work/build/gcc/ -B/usr/i686-pc-linux-gnu/bin/ -B/usr/i686-pc-linux-gnu/lib/ -isystem /usr/i686-p
c-linux-gnu/include' ' | sed -e 's,\(-[BI]\)\([^/][^:]\),\1../../\2,g;s,^\([^/][^:]*/\),../../\1,'`" PC
="`echo ./xgpc -B./' ' | sed -e 's,\(-[BI]\)\([^/][^:]\),\1../../\2,g;s,^\([^/][^:]*/\),../../\1,'`" CO
NFIG_SITE=nonexisting-file \
$src/p/rts/configure --silent > /dev/null --srcdir=$src/p/rts \
 `if [ x@with_shared@ = xyes ]; then echo '--with-shared'; fi`
cd ./p/rts && make CC="`echo /mnt/bigdisk1/tmp/portage/gpc-20040516/work/build/gcc/xgcc -B/mnt/bigdisk1
/tmp/portage/gpc-20040516/work/build/gcc/ -B/usr/i686-pc-linux-gnu/bin/ -B/usr/i686-pc-linux-gnu/lib/ -
isystem /usr/i686-pc-linux-gnu/include' ' | sed -e 's,\(-[BI]\)\([^/][^:]\),\1../../\2,g;s,^\([^/][^:]*
/\),../../\1,'`" PC="`echo ./xgpc -B./' ' | sed -e 's,\(-[BI]\)\([^/][^:]\),\1../../\2,g;s,^\([^/][^:]*
/\),../../\1,'`" GCC_VERSION="3.3.3" SHELL="/bin/sh" CFLAGS="-mcpu=athlon-xp -O3" PFLAGS="" AR="ar" AR_
FLAGS="rc" RANLIB="ranlib" RANLIB_TEST="[ -f ranlib ] || ( [ "i686-pc-linux-gnu" = "i686-pc-linux-gnu"
] && [ -f /usr/bin/ranlib -o -f /bin/ranlib ] )" RTSFLAGS="" DESTDIR="../.." all
make[2]: Entering directory `/mnt/bigdisk1/tmp/portage/gpc-20040516/work/build/gcc/p/rts'
echo '{ rts-config.inc.  Generated automatically from rts-config.h.  }' > rts-config.inc
../.././xgpc -B../.././  -I. -W -Wall -Wmissing-prototypes -Wmissing-declarations -mcpu=athlon-xp -O3
 --unit-path=/mnt/bigdisk1/tmp/portage/gpc-20040516/work/gcc-3.3.3/gcc/p/rts --automake --print-needed-
options "/mnt/bigdisk1/tmp/portage/gpc-20040516/work/gcc-3.3.3/gcc/p/rts/endian.pas" 2> "needed-options
" || true
sed -e 's,/\*,{,g;s,\*/,},g;s,^[ \t]*#\(.*\),{$\1},' rts-config.h >> rts-config.inc
../.././xgpc -B../.././  -c -I. -W -Wall -Wmissing-prototypes -Wmissing-declarations -mcpu=athlon-xp -O            3   --unit-path=/mnt/bigdisk1/tmp/portage/gpc-20040516/work/gcc-3.3.3/gcc/p/rts --automake `cat needed-            options` -DRTS_RELEASE_STRING="'`cat /mnt/bigdisk1/tmp/portage/gpc-20040516/work/gcc-3.3.3/gcc/p/rts/rt            s-version`'" -DGCC_VERSION="'3.3.3'" --interface-only /mnt/bigdisk1/tmp/portage/gpc-20040516/work/gcc-3            .3.3/gcc/p/rts/error.pas
if grep '^[^-]' "needed-options" > /dev/null; then echo "needed-options: `cat "needed-options"`" >&2; r            m -f "needed-options"; false; else true; fi
/mnt/bigdisk1/tmp/portage/gpc-20040516/work/build/gcc/xgcc -B/mnt/bigdisk1/tmp/portage/gpc-20040516/wor            k/build/gcc/ -B/usr/i686-pc-linux-gnu/bin/ -B/usr/i686-pc-linux-gnu/lib/ -isystem /usr/i686-pc-linux-gn            u/include  -c -I. -W -Wall -Wmissing-prototypes -Wmissing-declarations -mcpu=athlon-xp -O3  -Wpointer-a            rith -Wwrite-strings  /mnt/bigdisk1/tmp/portage/gpc-20040516/work/gcc-3.3.3/gcc/p/rts/rts.c
/mnt/bigdisk1/tmp/portage/gpc-20040516/work/gcc-3.3.3/gcc/p/rts/error.pas:38: error: file `rtsc.o' not             found
/mnt/bigdisk1/tmp/portage/gpc-20040516/work/gcc-3.3.3/gcc/p/rts/error.pas:38: error: file `string1.o' n            ot found
make[2]: *** [stamp-error-gpi] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory `/mnt/bigdisk1/tmp/portage/gpc-20040516/work/build/gcc/p/rts'
make[1]: *** [pascal.rts] Error 2
make[1]: Leaving directory `/mnt/bigdisk1/tmp/portage/gpc-20040516/work/build/gcc'
make: *** [all-gcc] Error 2

!!! ERROR: dev-lang/gpc-20040516 failed.
!!! Function src_compile, Line 106, Exitcode 2
!!! make failed

derk@zwift derk $ emerge info
Portage 2.0.50-r8 (default-x86-2004.0, gcc-3.3.3, glibc-2.3.3.20040420-r0, 2.6.6)
=================================================================
System uname: 2.6.6 i686 AMD Athlon(tm) XP 2500+
Gentoo Base System version 1.4.16
distcc 2.14 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
Autoconf: sys-devel/autoconf-2.59-r4
Automake: sys-devel/automake-1.8.5
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-mcpu=athlon-xp -O3 -pipe"
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/share/config /usr/lib/mozilla/defaults/pref /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-mcpu=athlon-xp -O3 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache cvs sandbox userpriv usersandbox"
GENTOO_MIRRORS="http://gentoo.oregonstate.edu http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/mnt/bigdisk1/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X aalib acpi acpi4linux alsa apm arts avi berkdb bonobo cdr crypt cups dvd dvdr encode esd f77 foomaticdb gb gdbm gif gnome gphoto2 gpm gtk gtk2 gtkhtml guile imagemagick imlib jack java javascript jpeg kde libg++ libgda libwww mad mikmod motif mozilla mpeg ncurses nls ofx oggvorbis opengl oss pam pdflib perl png ppds python qt quicktime readline scanner sdl slang spell ssl svga tcltk tcpd transcode truetype usb v4l x86 xinerama xml xml2 xmms xv zlib"

any ideas of how to fix ??
Comment 12 Derk W te Bokkel 2004-06-14 14:46:16 UTC
uh oh .. looks like make file order of dependency problems..
 files string1.o and rtcs.o do not exist yet since string1.pas and rtcs.pas are not compiled before error.pas ..
how to fix ?? is there some extra info needed in the ebuild or the makefile ?

(i'm sorry i've rarely worked with makefiles directly .. any good references?)
Comment 13 Mr. Bones. (RETIRED) gentoo-dev 2004-06-14 14:57:07 UTC
MAKEOPTS="-j1"
Comment 14 Derk W te Bokkel 2004-06-14 17:00:45 UTC
nope that's not a complete fix .. doing an emerge with this set.. which fails at the same spot.. then doing the 'ebuild gpc-20040516.ebuild compile install qmerge' command in the portage /dev-lang/gpc tree directory results in the compile finishing, then the ebuild install and qmerge finishes the job.  Bit of a pain but it works for now.
Comment 15 George Shapovalov (RETIRED) gentoo-dev 2004-06-14 17:14:18 UTC
Try reducing your C[XX]FLAGS. I see you are using -O3 for one. Its -funroll-loops (and various -unroll-more :)) are breaking things quite often. 

George
Comment 16 Derk W te Bokkel 2004-06-14 17:46:15 UTC
Doesn't look like a CFLAG kind of problem to me .. One of the machines it failed on was using -O2 instead of -O3 .. just rerunning the 'compile' comand again fixes the issue meaning the required files are created the second time in a dfferent order than before perhaps ..
Comment 17 George Shapovalov (RETIRED) gentoo-dev 2004-06-14 18:28:46 UTC
Ok, just committed the updated version. Passing MAKEOPTS="-j1" directly to emake, should fix it now. Wait half an hour and resync ;)..

George
Comment 18 Mr. Bones. (RETIRED) gentoo-dev 2004-06-14 18:40:26 UTC
Don't modify MAKEOPTS from the ebuild, that's for users to set.  If you need
to force make to only do one job at a time, use emake -j1 ....

There are lots of bad examples of modifying MAKEOPTS in portage, just ignore
those.
Comment 19 George Shapovalov (RETIRED) gentoo-dev 2004-06-14 19:09:40 UTC
>If you need to force make to only do one job at a time, use emake -j1 ....
Hm, I believe MAKEOPT="-j1" emake was recommended earlier on (at least in some emails to -dev), but that was quite some time ago and it does sound "unright" :). Anyway, emake -j1 works as well, ebuild adjusted yet again.

George