{standard input}:473: Error: symbol `m_libcassert_get_ip' is already defined {standard input}:667: Error: symbol `m_libcassert_get_ip' is already defined {standard input}:857: Error: symbol `m_libcassert_get_ip' is already defined make[3]: *** [libcoregrind_x86_linux_a-m_libcassert.o] Error 1 make[3]: Leaving directory `/var/tmp/portage/valgrind-3.1.1/work/valgrind-3.1.1/coregrind' make[2]: *** [all] Error 2 make[2]: Leaving directory `/var/tmp/portage/valgrind-3.1.1/work/valgrind-3.1.1/coregrind' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/valgrind-3.1.1/work/valgrind-3.1.1'make: *** [all] Error 2 !!! ERROR: dev-util/valgrind-3.1.1 failed. !!! Function src_compile, Line 61, Exitcode 2 Desktop # emerge --info Portage 2.0.54 (default-linux/x86/2005.1, gcc-3.4.5, glibc-2.3.5-r3, 2.6.15-gentoo-r1MD1 i686) ================================================================= System uname: 2.6.15-gentoo-r1MD1 i686 Intel(R) Pentium(R) 4 CPU 2.66GHz Gentoo Base System version 1.6.14 dev-lang/python: 2.3.5-r2, 2.4.2 sys-apps/sandbox: 1.2.12 sys-devel/autoconf: 2.13, 2.59-r7 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1 sys-devel/binutils: 2.16.1 sys-devel/libtool: 1.5.22 virtual/os-headers: 2.6.11-r2 ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CBUILD="i686-pc-linux-gnu" CFLAGS="-pipe -O3 -march=pentium4 -fomit-frame-pointer -finline-limit=1200" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.4/env /usr/kde/3.4/share/config /usr/kde/3.4/shutdown /usr/kde/3/share/config /usr/lib/X11/xkb /usr/lib/mozilla/defaults/pref /usr/share/config /var/qmail/control" CONFIG_PROTECT_MASK="/etc/eselect/compiler /etc/gconf /etc/terminfo /etc/texmf/web2c /etc/env.d" CXXFLAGS="-pipe -O3 -march=pentium4 -fomit-frame-pointer -finline-limit=1200" DISTDIR="/portage/distfiles" FEATURES="autoconfig distlocks sandbox sfperms strict" GENTOO_MIRRORS="http://mirror.pacific.net.au/linux/Gentoo http://mirror.isp.net.au/ftp/pub/gentoo/ http://ftp.swin.edu.au/gentoo" MAKEOPTS="-j2" PKGDIR="/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/portage" SYNC="rsync://rsync.au.gentoo.org/gentoo-portage" USE="x86 X Xaw3d alsa apm audiofile avi bash-completion berkdb bitmap-fonts bzip2 cairo cdr cli crypt cups curl dbus doc dri dvd dvdr eds emacs emacs-w3 emboss encode esd examples exif expat fam ffmpeg firefox font-server foomaticdb gd gdbm gif gimpprint glut gnome gnutls gstreamer gtk gtk2 gtkhtml guile hal howl idn imagemagick imlib ipv6 isdnlog jpeg kdeenablefinal kdexdeltas lcms libg++ libwww mad mikmod mmap mmx mng mono mp3 mpeg mppe-mppc ncurses nptl nptlonly nsplugin nvidia ogg oggvorbis openal opengl oss pam pcre pdf pdflib perl png pppd profile python qt quicktime readline reflection sdl session spell spl sse sse2 ssl svg tcltk tcpd tetex threads tiff truetype truetype-fonts type1-fonts udev unicode usb vorbis win32codecs wmf xml xml2 xorg xv zlib userland_GNU kernel_linux elibc_glibc" Unset: ASFLAGS, CTARGET, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTDIR_OVERLAY
I get the almost same error when compiling 'm_libcassert.c': {standard input}: Assembler messages: {standard input}:811: Error: symbol `m_libcassert_get_ip' is already defined make[3]: *** [libcoregrind_x86_linux_a-m_libcassert.o] Error 1 make[3]: Leaving directory `/var/tmp/portage/valgrind-3.1.1/work/valgrind-3.1.1/coregrind' make[2]: *** [all] Error 2 make[2]: Leaving directory `/var/tmp/portage/valgrind-3.1.1/work/valgrind-3.1.1/coregrind' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/valgrind-3.1.1/work/valgrind-3.1.1' make: *** [all] Error 2 !!! ERROR: dev-util/valgrind-3.1.1 failed. Call stack: ebuild.sh, line 1525: Called dyn_compile ebuild.sh, line 928: Called src_compile valgrind-3.1.1.ebuild, line 61: Called die ext@RURI% emerge --info %~ [1] Portage 2.1_pre9-r4 (default-linux/x86/2005.0, gcc-3.3.6, glibc-2.3.6-r3, 2.6.12-gentoo-r6 i686) ================================================================= System uname: 2.6.12-gentoo-r6 i686 AMD Athlon(tm) XP 1800+ Gentoo Base System version 1.12.0_pre18 dev-lang/python: 2.3.5, 2.4.2-r1 sys-apps/sandbox: 1.2.17 sys-devel/autoconf: 2.13, 2.59-r7 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2 sys-devel/binutils: 2.16.1-r2 sys-devel/libtool: 1.5.22 virtual/os-headers: 2.6.11-r5 ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CBUILD="i686-pc-linux-gnu" CFLAGS="-march=athlon-xp -O3 -pipe -fomit-frame-pointer" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/lib/mozilla/defaults/pref /usr/share/X11/xkb /usr/share/config /var/qmail/control" CONFIG_PROTECT_MASK="/etc/eselect/compiler /etc/gconf /etc/revdep-rebuild /etc/splash /etc/terminfo /etc/texmf/web2c /etc/env.d" CXXFLAGS="-march=athlon-xp -O3 -pipe -fomit-frame-pointer" DISTDIR="/usr/portage/distfiles" FEATURES="autoconfig distlocks metadata-transfer sandbox sfperms strict" GENTOO_MIRRORS="http://ds.thn.htu.se/linux/gentoo http://distfiles.gentoo.org" LC_ALL="sv_SE" LINGUAS="sv" MAKEOPTS="-j2" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage" USE="x86 X alsa apm avi berkdb bitmap-fonts cli crypt cups dri eds emboss encode firefox foomaticdb fortran gdbm gif gpm gstreamer gtk gtk2 imlib ipv6 isdnlog jikes jpeg libg++ libwww mad mikmod motif mozilla mp3 mpeg ncurses nls nptl nptlonly ogg oggvorbis opengl oss pam pcre pdflib perl png pppd python qt quicktime readline reflection session spell spl ssl svga tcpd truetype truetype-fonts type1-fonts unicode userlocales vorbis xml2 xmms xorg xv zlib elibc_glibc input_devices_-acecad input_devices_-aiptek input_devices_-calcomp input_devices_-citron input_devices_-digitaledge input_devices_-dmc input_devices_-dynapro input_devices_-elo2300 input_devices_-elographics input_devices_evdev input_devices_-fpit input_devices_-hyperpen input_devices_-jamstudio input_devices_-joystick input_devices_keyboard input_devices_-magellan input_devices_-magictouch input_devices_-microtouch input_devices_mouse input_devices_-mutouch input_devices_-palmax input_devices_-penmount input_devices_-spaceorb input_devices_-summa input_devices_-synaptics input_devices_-tek4957 input_devices_-ur98 input_devices_-vmmouse input_devices_-void input_devices_-wacom kernel_linux linguas_sv userland_GNU video_cards_-apm video_cards_-ark video_cards_-chips video_cards_-cirrus video_cards_-cyrix video_cards_-dummy video_cards_-fbdev video_cards_-fglrx video_cards_-glint video_cards_-i128 video_cards_-i740 video_cards_-i810 video_cards_-imstt video_cards_-mach64% video_cards_-mga video_cards_-neomagic video_cards_-nsc video_cards_-nv video_cards_nvidia video_cards_-r128% video_cards_-radeon% video_cards_-rendition video_cards_-s3 video_cards_-s3virge video_cards_-savage video_cards_-siliconmotion video_cards_-sis video_cards_-sisusb video_cards_-tdfx video_cards_-tga video_cards_-trident video_cards_-tseng video_cards_-v4l video_cards_-vesa video_cards_vga video_cards_-via video_cards_-vmware video_cards_-voodoo" Unset: ASFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LDFLAGS, PORTDIR_OVERLAY
This is a bug in gcc 3.3.x and apparently also in 3.4.5. (See bug #129776) Matt, can you confirm that the problem goes away if you use -O2 instead of -O3?
Switching to -O2 worked for me, and using i686-pc-linux-gnu-3.4.6 also worked (with -O3).
This is a bug in gcc that apparently has been fixed in 3.4.5-r1 and up. gcc 3.4.5-r1 is stable, so I'm marking this as a duplicate of 129776. *** This bug has been marked as a duplicate of 129776 ***