Doing 'emerge -uv --deep world', guile on my system should be updated from 1.4.1 to 1.6.4. While making files I get : [...] cat alist.doc arbiters.doc async.doc backtrace.doc boolean.doc chars.doc continuations.doc debug.doc dynl.doc dynwind.doc environments.doc eq.doc error.doc eval.doc evalext.doc extensions.doc feature.doc fluids.doc fports.doc gc.doc goops.doc gsubr.doc guardians.doc hash.doc hashtab.doc hooks.doc init.doc ioext.doc iselect.doc keywords.doc lang.doc list.doc load.doc macros.doc mallocs.doc modules.doc numbers.doc objects.doc objprop.doc options.doc pairs.doc ports.doc print.doc procprop.doc procs.doc properties.doc random.doc rdelim.doc read.doc root.doc rw.doc scmsigs.doc script.doc simpos.doc smob.doc sort.doc srcprop.doc stackchk.doc stacks.doc stime.doc strings.doc strop.doc strorder.doc strports.doc struct.doc symbols.doc throw.doc values.doc variable.doc vectors.doc version.doc vports.doc weaks.doc symbols-deprecated.doc ramap.doc unif.doc filesys.doc posix.doc net_db.doc socket.doc regex-posix.doc | GUILE="/home/portage/tmp/portage/guile-1.6.4/work/guile-1.6.4/pre-inst-guile" ../scripts/snarf-check-and-output-texi --manual > guile.texi || { rm guile.texi; false; } make[2]: *** [guile.texi] Erreur 1 [...] Similar behavior has already been reported twice in the forums without any good workaround : - x86 : http://forums.gentoo.org/viewtopic.php?t=72945&highlight=guile - ppc : http://forums.gentoo.org/viewtopic.php?t=72916&highlight=guile In fact this error is due to a segmentation fault running the newly compiled binary libguile/.libs/lt-guile (called by the script). The function scm_mark_locations seems to be called with a huge internal stack length. This length is calculated by scm_stack_size which depends on a #define (SCM_STACK_GROWS_UP) set by configure. With CFLAGS="-O3 -pipe -mcpu=750" configure define SCM_STACK_GROWS_UP (according to what I found on the net, that's wrong, ppc stack, like x86, grows down) ; with CFLAGS="" SCM_STACK_GROWS_UP is not set. So I guess the code used in configure to find the stack direction is not immune to compiler optimization flags. Reproducible: Always Steps to Reproduce: 1. 2. 3. emerge info : Portage 2.0.49-r2 (default-ppc-1.4, gcc-3.2.3, glibc-2.2.5-r4,2.3.2-r1, 2.4.21-ppc-r2) ================================================================= System uname: 2.4.21-ppc-r2 ppc ACCEPT_KEYWORDS="ppc ~ppc" AUTOCLEAN="yes" CFLAGS="-O3 -pipe -mcpu=750" CHOST="powerpc-unknown-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="-O3 -pipe -mcpu=750" DISTDIR="/home/portage/distfiles" FEATURES="ccache" GENTOO_MIRRORS="http://194.83.57.11/sites/www.ibiblio.org/gentoo/ http://ftp.snt.utwente.nl/pub/os/linux/gentoo http://194.83.57.7/sites/www.ibiblio.org/gentoo/ http://194.83.57.2/sites/www.ibiblio.org/gentoo/ http://194.83.57.3/sites/www.ibiblio.org/gentoo/" MAKEOPTS="-j2" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/home/portage/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="" SYNC="rsync://rsync.fr.gentoo.org/gentoo-portage" USE="oss xv jpeg nls mitshm gif png truetype ppc foomaticdb gnome-libs gdbm berkdb slang readline bonobo tcltk guile X sdl gpm tcpd pam libwww perl python esd imlib gnome gtk motif opengl mozilla alsa cups gd spell pdflib java xface crypt -kde avi mpeg quicktime flash gtkhtml -qt dvd oggvorbis ssl -mysql" tail -20 config.log : #define PACKAGE_NAME "" #define PACKAGE_STRING "" #define PACKAGE_TARNAME "" #define PACKAGE_VERSION "" #define READER_EXTENSIONS 1 #define RETSIGTYPE void #define SCM_DEBUG_DEPRECATED 0 #define SCM_SINGLES 1 #define SCM_STACK_GROWS_UP 1 #define SCM_WARN_DEPRECATED_DEFAULT "summary" #define SIZEOF_INT 4 #define SIZEOF_LONG 4 #define SIZEOF_LONG_LONG 8 #define SIZEOF_VOID_P 4 #define STDC_HEADERS 1 #define STDC_HEADERS 1 #define TIME_WITH_SYS_TIME 1 #define WORDS_BIGENDIAN 1
You need to lower your CFLAGS & CXXFLAGS. I tried it with "-O3 -pipe -mcpu=750" and that didn't work. It worked when I used "-O1 -pipe -mcpu=750"
Yes I guess that should work (I've done a workaround that may be similar). In fact the source code runs fine with -O3 flag, it's only the m4 macro in configure which incorrectly reports the direction of the stack (in details, a program is compiled and compare the address of local vars between main and a function called. Without optimization the answer is correct, with -03 the address are identical and the answer should be unknown and make the configure fail, but it's only a binary answer : if it don't grows down it is assumed it grows up). I've found some discussion threads on the subject on the net : the address are the same because gcc detects one the local vars is never assigned and so is useless... According to an answer it's a bug in gcc since ANSI requires to different objects to have different locations... I'm not good enough in C to conclude.
Oliver, thanks for documenting your info on the bug here, with that information I was able to create a fix. I have just compiled guile on ppc with -O3. The configure file should be patched as follows (I suspect this patch should be applied to configure.in and sent upstream): --- configure.orig 2004-02-25 19:54:59.000000000 +1030 +++ configure 2004-02-25 21:09:50.000000000 +1030 @@ -17479,8 +17479,8 @@ cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ aux (l) unsigned long l; - { int x; exit (l >= ((unsigned long)&x)); } - main () { int q; aux((unsigned long)&q); } + { volatile int x; x = l; exit (l >= ((unsigned long)&x)); } + main () { int q; aux((unsigned long)&q); } _ACEOF rm -f conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
I'm glad it helped you, but anyway it looks like gcc has a faulty behavior...
I have reproduced this error. Will look into fixing it.
for future reference pvdabeel, you cant go around ripping KEYWORDS out of packages just because they failed to build on *your* box in this case, 1.6.4 builds just fine on my ppc, and the reporter even noted that this doesnt seem to be ppc-specific (failed on x86 same exact way) because you decided to go removing ppc from KEYWORDS you left other packages in the tree broken: games-action/trackballs/trackballs-1.0.0.ebuild: ~ppc ['>=dev-util/guile-1.6*'] ive gone ahead and added ppc back to the ebuilds like they were since this is *not* a ppc bug
The texi-error occurs on upgrading fom 1.6.4-r1 to 1.6.6, too. The only problem is that I can't patch the configure-script as below because the guile-macos-posix.patch failes on applying it to an old /var/tmp/portage/guile... tree more than once which prevents me from patching manually the configure-skript...
Bug 86415: http://bugs.gentoo.org/show_bug.cgi?id=86415 may be a duplicate of this bug. SpanKY, how did you build it on your ppc?
*** Bug 85670 has been marked as a duplicate of this bug. ***
there's been a replace-flag in guile for a while for -O3, so i can only think that is the only solution so far unless the ppc guys come up with something better. closing for now.