When emerging flightgear 0.9.4 it fails during compilation with the following: g++ -DPKGLIBDIR=\"/usr/games/lib/FlightGear\" -march=athlon-tbird -O3 -pipe -fforce-addr -fomit-frame-pointer -funroll-loops -falign-functions=4 -maccumulate-outgoing-args -D_REENTRANT -L/usr/games/lib -L/usr/X11R6/lib -o fgfs bootstrap.o ../../src/Main/libMain.a ../../src/Aircraft/libAircraft.a ../../src/ATC/libATC.a ../../src/Cockpit/libCockpit.a ../../src/Cockpit/built_in/libBuilt_in.a ../../src/Controls/libControls.a ../../src/FDM/libFlight.a ../../src/FDM/Balloon/libBalloon.a ../../src/FDM/ExternalNet/libExternalNet.a ../../src/FDM/ExternalPipe/libExternalPipe.a ../../src/FDM/JSBSim/libJSBSim.a ../../src/FDM/YASim/libYASim.a ../../src/FDM/JSBSim/filtersjb/libfiltersjb.a ../../src/FDM/LaRCsim/libLaRCsim.a ../../src/FDM/UIUCModel/libUIUCModel.a ../../src/GUI/libGUI.a ../../src/Autopilot/libAutopilot.a ../../src/Input/libInput.a ../../src/Instrumentation/libInstrumentation.a ../../src/Model/libModel.a ../../src/AIModel/libAIModel.a ../../src/Network/libNetwork.a ../../src/Navaids/libNavaids.a ../../src/Scenery/libScenery.a ../../src/Scripting/libScripting.a ../../src/Sound/libSound.a ../../src/Airports/libAirports.a ../../src/MultiPlayer/libMultiPlayer.a ../../src/Replay/libReplay.a ../../src/Systems/libSystems.a ../../src/Time/libTime.a ../../src/Environment/libEnvironment.a -lsgclouds3d -lsgroute -lsgsky -lsgsound -lsgephem -lsgmaterial -lsgtgdb -lsgmodel -lsgtiming -lsgio -lsgscreen -lsgmath -lsgbucket -lsgprops -lsgdebug -lsgmagvar -lsgmisc -lsgnasal -lsgxml -lsgsound -lsgserial -lsgstructure -lsgenvironment -lsgthreads -lpthread -lplibpu -lplibfnt -lplibjs -lplibnet -lplibssg -lplibsg -lplibul -lz -lglut -lGLU -lGL -lXmu -lXt -lSM -lICE -lXi -lXext -lX11 -ldl -lm -lplibsl -lplibsm /usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.3/../../../libsgsky.a(cloud.o)(.text+0x22e9): In function `SGCloudLayer::draw()': : undefined reference to `ssgCullAndDraw(ssgRoot*)' /usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.3/../../../libsgsky.a(sky.o)(.text+0xab3): In function `SGSky::preDraw(float, float)': : undefined reference to `ssgCullAndDraw(ssgRoot*)' collect2: ld returned 1 exit status make[2]: *** [fgfs] Error 1 make[2]: Leaving directory `/var/tmp/portage/flightgear-0.9.4/work/FlightGear-0.9.4/src/Main' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/flightgear-0.9.4/work/FlightGear-0.9.4/src' make: *** [all-recursive] Error 1 dev-games/simgear = 0.3.5 media-libs/plib = 1.8.2 dev-db/metakit = 2.4.9.2-r1 media-libs/glut = 3.7-r2 Reproducible: Always Steps to Reproduce: 1.emerge games-simulation/flightgear 2. 3. Actual Results: Same results Expected Results: Emerged Portage 2.0.50-r3 (default-x86-1.4, gcc-3.3.3, glibc-2.2.5-r2,2.3.3_pre20040207-r0, 2.4.20-gaming-r8) ================================================================= System uname: 2.4.20-gaming-r8 i686 AMD Athlon(tm) Processor Gentoo Base System version 1.4.3.13p1 Autoconf: sys-devel/autoconf-2.59-r3 Automake: sys-devel/automake-1.8.2 ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CFLAGS="-march=athlon-tbird -O3 -pipe -fforce-addr -fomit-frame-pointer -funroll-loops -falign-functions=4 -maccumulate-outgoing-args" CHOST="i686-pc-linux-gnu" COMPILER="gcc3" CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config /usr/kde/3.1/share/config /usr/kde/3.2/share/config /usr/kde/3/share/config /usr/lib/mozilla/defaults/pref /usr/share/config /var/bind /var/qmail/alias /var/qmail/control" CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d" CXXFLAGS="-march=athlon-tbird -O3 -pipe -fforce-addr -fomit-frame-pointer -funroll-loops -falign-functions=4 -maccumulate-outgoing-args" DISTDIR="/usr/portage/distfiles" FEATURES="autoaddcvs ccache sandbox" GENTOO_MIRRORS="http://gentoo.oregonstate.edu http://distro.ibiblio.org/pub/Linux/distributions/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="X alsa apm arts avi berkdb bonobo cdr crypt cups encode esd foomaticdb gdbm gif gnome gphoto2 gpm gtk gtk2 gtkhtml guile imlib java jpeg kde libg++ libwww mad mikmod motif mozilla mpeg mysql ncurses nls oggvorbis opengl oss pam pdflib perl png python qt quicktime readline scanner sdl slang snmp spell ssl svga tcltk tcpd truetype x86 xml2 xmms xv zlib"
CFLAGS="-march=athlon-tbird -O3 -pipe -fforce-addr -fomit-frame-pointer -funroll-loops -falign-functions=4 -maccumulate-outgoing-args" before I attempt to even start debugging this, I'd like you to please tone down your optimisations to "-march=athlon-tbird -O2" and re-attempt this emerge then we'll talk.
I have the same error with flightgear-0.9.4 with slightly newer versions of metakit (dev-db/metakit-2.4.9.3-r2) and glut (media-libs/glut-3.7.1), simgear and plib is same as reporter. i tried to compile it with CFLAGS set to -march=pentium4 -O2 and with no CFLAGS at all (commented out in make.conf) and in both cases it also failed at the same place, as it did with the harsher CFLAGS i had before Portage 2.0.50-r5 (default-x86-1.4, gcc-3.3.3, glibc-2.3.3_pre20040207-r0, 2.6.5-rc3-love1) ================================================================= System uname: 2.6.5-rc3-love1 i686 Intel(R) Pentium(R) 4 CPU 2.00GHz Gentoo Base System version 1.4.6 distcc 2.13 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled] ccache version 2.3 [disabled] Autoconf: sys-devel/autoconf-2.59-r3 Automake: sys-devel/automake-1.8.3 ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CFLAGS="-march=pentium4 -O2" 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="-march=pentium4 -O2" DISTDIR="/usr/portage/distfiles" FEATURES="autoaddcvs sandbox" GENTOO_MIRRORS="http://ds.thn.htu.se/linux/gentoo http://gentoo.oregonstate.edu" MAKEOPTS="-j2" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/usr/local/portage /usr/local/overlays/bmg-main" SYNC="rsync://192.168.0.219/gentoo-portage" USE="X aalib acpi acpi4linux alsa autofs avi berkdb bonobo cdr crypt cups curl dga encode foomaticdb gd gdbm gif gphoto2 gpm gtk gtk2 gtkhtml guile imlib jabber java jpeg libg++ libwww mad maildir matroska mmx motif mozilla moznocompose moznoirc moznomail mozsvg mpeg mysql ncurses nls nptl oggvorbis opengl oscar oss pam pdflib perl png ppds python qt quicktime readline samba scanner sdl slang spell sse ssl svga tcltk tcpd tiff truetype usb v4l wmf x86 xine xml2 xmms xv xvid zlib"
Sorry I didn't try that earlier, but alas -- same result with CFLAGS="--march=athlon-tbird -O2" : /usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.3/../../../libsgsky.a(cloud.o)(.text+0x22e9): In function `SGCloudLayer::draw()': : undefined reference to `ssgCullAndDraw(ssgRoot*)' /usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.3/../../../libsgsky.a(sky.o)(.text+0xab3): In function `SGSky::preDraw(float, float)': : undefined reference to `ssgCullAndDraw(ssgRoot*)' collect2: ld returned 1 exit status make[2]: *** [fgfs] Error 1 make[2]: Leaving directory `/var/tmp/portage/flightgear-0.9.4/work/FlightGear-0.9.4/src/Main' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/flightgear-0.9.4/work/FlightGear-0.9.4/src' make: *** [all-recursive] Error 1 There also is an interesting error that happens slightly prior to the fatal one. I have no idea the significance of it, but nonetheless here it is: g++ -DHAVE_CONFIG_H -I. -I. -I../../src/Include -I../.. -I../../src -I/usr/X11R6/include -DPKGLIBDIR=\"/usr/games/lib/FlightGear\" -march=athlon-tbird -O2 -D_REENTRANT -c -o bootstrap.o `test -f bootstrap.cxx || echo './'`bootstrap.cxx make[2]: *** No rule to make target `../../src/Main/libMain.a', needed by `fgfs'. Stop. make[2]: *** Waiting for unfinished jobs.... make[2]: Leaving directory `/var/tmp/portage/flightgear-0.9.4/work/FlightGear-0.9.4/src/Main' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/flightgear-0.9.4/work/FlightGear-0.9.4/src' make: *** [all-recursive] Error 1 Making all in tests Anyway, anything more I can do to test out things, let me know. Regards, Jeff
what about `env MAKEOPTS=-j1 emerge flightgear`
All righty, After googling ssgCullAndDraw(ssgRoot*), I found the general feeling was that it was a plib thing. The following steps rectified the compile: 1. emerge -C simgear 2. emerge -C plib 3. emerge plib 4. emerge simgear 5. emerge flightgear 6. success and happiness I have no idea if I needed to ditch the simgear, but I figured why not start out totally fresh. I guess something was hanging around from an older plib or something. Anyway, it has compiled properly, even with the optimized CFLAGS I original started with. Regards, Jeff
Sounds like things are working for you. I'll go ahead and close.