cc -Wdeclaration-after-statement -fno-PIC -O4 -D__STDC_LIMIT_MACROS -march=i486 -mtune=i686 -pipe -ffast-math -fomit-frame-pointer -D_REENTRANT -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -I/usr/X11R6/include -I/usr/kde/3.5/include/artsc -pthread -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/freetype2 -I. -I./libavutil -I./libavcodec -o mplayer mplayer.o m_property.o mp_msg.o asxparser.o codec-cfg.o cpudetect.o edl.o find_sub.o m_config.o m_option.o m_struct.o parser-cfg.o playtree.o playtreeparser.o spudec.o sub_cc.o subreader.o vobsub.o unrarlib.o mixer.o parser-mpcmd.o subopt-helper.o libvo/libvo.a libao2/libao2.a input/libinput.a libmenu/libmenu.a libmpcodecs/libmpcodecs.a loader/libloader.a loader/dshow/libDS_Filter.a loader/dmo/libDMO_Filter.a libaf/libaf.a libmpdemux/libmpdemux.a stream/stream.a libswscale/libswscale.a osdep/libosdep.a -Wl,-z,noexecstack -ldvdread libavformat/libavformat.a libavcodec/libavcodec.a libavutil/libavutil.a libpostproc/libpostproc.a -lmad -ltheora -logg -llzo -lxvidcore -ldts -lpng -lz -lz -ljpeg -lasound -ldl -lpthread -lspeex -lfaac -lncurses -lcdda_interface -lcdda_paranoia -lgif -lsmbclient -lpthread -ldl -rdynamic -lm libfaad2/libfaad2.a mp3lib/libMP3.a liba52/liba52.a libmpeg2/libmpeg2.a tremor/libvorbisidec.a libass/libass.a -lfontconfig -lfreetype -lz -lGL -ldl -lXv -lXvMC -lXvMCW -lXxf86vm -lXext -lX11 -lpthread -L/usr/kde/3.5/lib -ldl -lartsc -lpthread -lgmodule-2.0 -ldl -lgthread-2.0 -lglib-2.0 mp3lib/libMP3.a(dct64_sse.o): In function `dct64_sse': dct64_sse.c:(.text+0xc): undefined reference to `costab_mmx' dct64_sse.c:(.text+0x47): undefined reference to `costab_mmx' dct64_sse.c:(.text+0x7f): undefined reference to `costab_mmx' dct64_sse.c:(.text+0xb7): undefined reference to `costab_mmx' dct64_sse.c:(.text+0x1bd): undefined reference to `costab_mmx' mp3lib/libMP3.a(dct64_sse.o):dct64_sse.c:(.text+0x1ce): more undefined references to `costab_mmx' follow collect2: ld returned 1 exit status make: *** [mplayer] Error 1 Portage 2.1.2_rc1-r6 (default-linux/x86/2006.1, gcc-4.1.1, glibc-2.5-r0, 2.6.18.1 i686) ================================================================= System uname: 2.6.18.1 i686 Intel(R) Pentium(R) 4 CPU 3.20GHz Gentoo Base System version 1.12.6 Last Sync: Wed, 15 Nov 2006 01:47:01 +0000 ccache version 2.4 [disabled] dev-java/java-config: 1.3.7, 2.0.30 dev-lang/python: 2.4.4 dev-python/pycrypto: 2.0.1-r5 dev-util/ccache: 2.4-r6 dev-util/confcache: 0.4.2-r1 sys-apps/sandbox: 1.2.18.1 sys-devel/autoconf: 2.13, 2.60 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10 sys-devel/binutils: 2.17 sys-devel/gcc-config: 1.3.14 sys-devel/libtool: 1.5.22 virtual/os-headers: 2.6.17-r1 ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CBUILD="i686-pc-linux-gnu" CFLAGS="-O3 -march=pentium4 -fomit-frame-pointer -pipe" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config" CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c" CXXFLAGS="-O3 -march=pentium4 -fomit-frame-pointer -pipe" DISTDIR="/gentoo/distfiles" FEATURES="autoconfig distlocks metadata-transfer parallel-fetch sandbox sfperms strict" GENTOO_MIRRORS="http://ftp.easynet.nl/mirror/gentoo/ http://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/ ftp://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/ http://ftp.easynet.nl/mirror/gentoo/ http://ftp.snt.utwente.nl/pub/os/linux/gentoo http://ftp.uni-erlangen.de/pub/mirrors/gentoo http://gentoo.osuosl.org" LINGUAS="de" MAKEOPTS="-j1" PKGDIR="/usr/portage/packages" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages" PORTAGE_TMPDIR="/gentoo/build" PORTDIR="/gentoo/portage" PORTDIR_OVERLAY="/gentoo/build/overlay" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="x86 X Xaw3d a52 aac acl acpi activefilter akode alsa aotuv arts audiofile bash-completion berkdb bitmap-fonts bogofilter bzip2 caps cdda cddb cdio cdparanoia chipcard cli cpudetection cracklib crypt cups curl dbus dlloader doc dri dtaus dts dvd dvdread dynamic edl elibc_glibc emacs fam ffmpeg flac font-server foomaticdb fuse gd-external gdbm geldkarte gif glibc-omitfp glut gnutls gpg2-experimental gpm gsnd gstreamer hal hardened hbci httpd i8x0 iconv icq idn imagemagick imap imlib input_devices_keyboard input_devices_mouse ipppd irmc isdnlog jpeg jpeg2k kcal kde kdehiddenvisibility kernel_linux latex lcms ldap ldapsam libg++ linguas_de lzo mad madwifi maildir mbox mime mjpeg mng motif mozsvg mp3 mpeg mplayer mule musicbrainz ncurses nls no-old-linux noantlr nobcel nobeanutils nobsh nocommonslogging nocommonsnet nojdepend nojsch nojython nolog4j nooro noregexp norhino noxalan noxerces nptl nptlonly nsplugin objc objc++ objc-gc ofx ogg oggvorbis openexr opengl pam pam_console pcre pdf perl perlsuid pg-intdatetime pic png ppds pppd pwdb python qt3 qt4 quicktime rdesktop readline real reflection rtc samba savedconfig session slang slp socks5 speedo speex spell spl sql sqlite sqlite3 sse ssl stream subversion svg symlink sysfs tcpd tetex theora threads tiff toolbar truetype truetype-fonts type1-fonts udev unicode userland_GNU userlocales vcd video_cards_i810 vidix vim-pager vim-with-x vlm vorbis win32codecs wxwindows xim xine xml xorg xosd xprint xscreensaver xv xvid xvmc zeroconf zlib" Unset: CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, PORTAGE_RSYNC_EXTRA_OPTS
I had the same problem, adding mmx and mmxext to the USE flags fixes the problem. I did not try with only one of these flags, or without other flags like sse. emerge --info if it can help (the non-working configuration is the same, without these two USE flags): emerge --info Portage 2.1.2_rc1-r6 (default-linux/x86/2006.0, gcc-4.1.1, glibc-2.5-r0, 2.6.18-mactel i686) ================================================================= System uname: 2.6.18-mactel i686 Genuine Intel(R) CPU T2400 @ 1.83GHz Gentoo Base System version 1.12.6 Last Sync: Fri, 17 Nov 2006 10:20:01 +0000 ccache version 2.4 [enabled] dev-java/java-config: 1.3.7, 2.0.30 dev-lang/python: 2.4.4 dev-python/pycrypto: 2.0.1-r5 dev-util/ccache: 2.4-r6 sys-apps/sandbox: 1.2.18.1 sys-devel/autoconf: 2.13, 2.60 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10 sys-devel/binutils: 2.17 sys-devel/gcc-config: 1.3.14 sys-devel/libtool: 1.5.22 virtual/os-headers: 2.6.17-r1 ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CBUILD="i686-pc-linux-gnu" CFLAGS="-march=pentium-m -Os -pipe -msse -msse2 -msse3" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config" CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c" CXXFLAGS="-O2 -mcpu=i686 -pipe" DISTDIR="/usr/portage/distfiles" FEATURES="autoconfig ccache distlocks metadata-transfer parallel-fetch sandbox sfperms strict userpriv usersandbox" GENTOO_MIRRORS="http://mirror.pacific.net.au/linux/Gentoo/ http://ftp.gentoo.or.kr/ http://ftp.ucsb.edu/pub/mirrors/linux/gentoo/ ftp://ftp.ucsb.edu/pub/mirrors/linux/gentoo/" LINGUAS="en fr zh" MAKEOPTS="-j3" PKGDIR="/usr/portage/packages" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/usr/local/portage /usr/portage/local/layman/java-experimental /usr/portage/local/layman/portage-xgl /usr/portage/local/layman/liquidx" SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage" USE="x86 X a52 aac acpi alsa amr berkdb bitmap-fonts cairo cracklib crypt cups dbus dlloader dri elibc_glibc encode exif firefox gdbm gif glitz gnome gstreamer gtk gtk2 iconv imlib input_devices_keyboard input_devices_mouse input_devices_synaptics java jpeg kernel_linux kqemu libwww linguas_en linguas_fr linguas_zh mad madwifi matroska mikmod mmx mmxext motif mp3 mpeg ncurses nls no-seamonkey nptl nptlonly nsplugin ogg opengl pam passwordsave pcre pdf perl png python quicktime readline real samba sdl session speex spell sse sse2 ssl stream svg tcpd theora threads truetype truetype-fonts type1-fonts udev unicode usb userland_GNU v4l2 video_cards_fbdev video_cards_fglrx video_cards_vesa vorbis win32codecs wxwindows x264 xml xorg xv xvid zlib" Unset: CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, PORTAGE_RSYNC_EXTRA_OPTS
(In reply to comment #1) > I had the same problem, adding mmx and mmxext to the USE flags fixes the > problem. I did not try with only one of these flags, or without other flags > like sse. I tried adding mmxext first (since it's a local flag), which resulted in different errors. I then also added mmx, which made mplayer compile fine.
As MPlayer assumes it, flags should imply each other as on a real CPU, i.e. SSE3->SSE2->SSE->MMX2->MMX 3DNOW2->3DNOW->MMX etc. Esp. SSE without MMX makes no sense, there is no way to use SSE without MMX since it uses the same registers.
Created attachment 104136 [details, diff] possible fix in ebuild This change to the ebuild can make it work even with stupid use-flags USE="-mmx sse" It has to be checked for which other use-flags mmx has to be enabled. Or just closing this bug as WONTFIX :)
The problem should be valid for every program using SIMD on x86... Anyway the patch looks ok, commit if you like
*** Bug 162051 has been marked as a duplicate of this bug. ***
Still happening...just to bump the bug I guess. Portage 2.1.2-r9 (default-linux/x86/2006.1, gcc-4.1.1, glibc-2.5-r0, 2.6.19.1 i686) ================================================================= System uname: 2.6.19.1 i686 Intel(R) Pentium(R) 4 CPU 3.06GHz Gentoo Base System release 1.12.9 Timestamp of tree: Sat, 17 Feb 2007 13:30:01 +0000 dev-java/java-config: 1.3.7, 2.0.31 dev-lang/python: 2.4.3-r4 dev-python/pycrypto: 2.0.1-r5 sys-apps/sandbox: 1.2.17 sys-devel/autoconf: 2.13, 2.61 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10 sys-devel/binutils: 2.16.1-r3 sys-devel/gcc-config: 1.3.14 sys-devel/libtool: 1.5.22 virtual/os-headers: 2.6.17-r2 ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CBUILD="i686-pc-linux-gnu" CFLAGS="-O2 -march=pentium4 -pipe" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config" CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c" CXXFLAGS="-O2 -march=pentium4 -pipe" DISTDIR="/in/portage" FEATURES="autoconfig distlocks metadata-transfer sandbox sfperms strict" GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo" MAKEOPTS="-j2" PKGDIR="/usr/portage/packages" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="X a52 aac alsa apache2 arts bash-completion berkdb bitmap-fonts branding bzip2 cairo cdda cddb cli cracklib crypt cups curl dbus dlloader dri dvd dvdread eds encode ffmpeg firefox flac foomaticdb fortran gd gdbm gif gimpprint gnome gphoto2 gpm gstreamer gtk gtkhtml hal iconv imap imlib ipv6 isdnlog java jpeg kde kdeenablefinal lame libg++ libwww lm_sensors mad maildir matroska midi mikmod mng motif mp3 mpeg ncurses nls nptl nptlonly nsplugin nvidia ogg openal opengl oss pam pcre pdf perl php png postfix postgres ppds pppd python qt3 qt4 quicktime readline real reflection sasl scanner sdl session snmp sound spell spl sse sse2 ssl tcpd tetex theora tiff tk truetype truetype-fonts type1-fonts unicode usb vcd vorbis webdav win32codecs wxwindows x86 xinerama xml xorg xv xvid zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" ELIBC="glibc" INPUT_DEVICES="keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" USERLAND="GNU" VIDEO_CARDS="nvidia" Unset: CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY
Fixed in CVS