running enigma with libsdl-1.2.6 or libsdl-1.2.6-r1 crashes within 2 seconds with an Illegal instruction. Downgrading to libsdl-1.2.5-r2 solves the problem. gdb enigma gives the following information: Program received signal SIGILL, Illegal instruction. [Switching to Thread 16384 (LWP 11515)] 0x40033bc0 in BlitRGBtoRGBPixelAlphaMMX3DNOW () from /usr/lib/libSDL-1.2.so.0 Reproducible: Always Steps to Reproduce: 1. emerge enigma 2. emerge rsync 3. emerge world -u -p 4. enigma Actual Results: The program shows the title screen and disappears. The command prompt displays the text "Illegal instruction" Expected Results: Not crashed emerge info Portage 2.0.49-r13-2 (default-x86-1.4, gcc-3.2.3, glibc-2.3.2-r1, 2.4.22) ================================================================= System uname: 2.4.22 i686 Intel(R) Pentium(R) 4 CPU 2.60GHz Gentoo Base System version 1.4.3.10p1 ccache version 2.2 [enabled] ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CFLAGS="-march=pentium4 -O3 -pipe" CHOST="i686-pc-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 /usr/kde/3.1/share/config /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/" CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d" CXXFLAGS="-march=pentium4 -O3 -pipe" DISTDIR="/usr/portage/distfiles" FEATURES="autoaddcvs sandbox ccache buildpkg" GENTOO_MIRRORS="http://ftp.easynet.nl/mirror/gentoo/ http://gentoo.mirror.sdv.fr http://ftp.snt.utwente.nl/pub/os/linux/gentoo http://ftp.gentoo.skynet.be/pub/gentoo/ http://mirrors.sec.informatik.tu-darmstadt.de/gentoo" MAKEOPTS="-j4" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="x86 oss apm avi crypt encode foomaticdb gif jpeg gnome libg++ mad mikmod mpeg ncurses nls pdflib png quicktime spell truetype xml2 xmms xv zlib gtkhtml gdbm berkdb slang readline arts tetex bonobo svga ggi java guile mysql X sdl gpm tcpd pam libwww ssl perl python imlib oggvorbis gtk qt kde motif opengl mozilla acpi alsa cdr dvd esd gphoto2 pcmcia pda pnp aalib cups"
could you try this ? export EXTRA_ECONF="--disable-nasm" emerge libsdl
Okay, I've tried that. It gives exactly the same problem as I had originally.
I've been looking at the source code, unencumbered by much linux programming knowledge... The problem seems to occur in BlitRGBtoRGBPixelAlphaMMX3DNOW, which is interesting as my P4 doesn't have any 3DNow instructions. Looking for the function call we see in src/video/SDL_blit_A.c line 1457 f=CPU_Flags(); if((f&(TDNOW_CPU|MMX_CPU))==(TDNOW_CPU|MMX_CPU)) return BlitRGBtoRGBPixelAlphaMMX3DNOW; CPU_Flags seems to be the result of a cpuid call, EAX=1 - standard level flags. Unfortunately, as far as I can see, the 3dnow flag is not part of the standard level flags, but part of the extended level flags (see http://www.sandpile.org/ia32/cpuid.htm). The code checks the correct bit, but doesn't have the necessary information available. Again, without much further knowledge, I would evaluate this as a libSDL bug. Hope this makes sense.
I ran into this also (with castle-combat). Looking at the sdl archives they know about it and have a plan to fix it. Until then I'll just run 1.2.5
*** Bug 30643 has been marked as a duplicate of this bug. ***
*** Bug 29205 has been marked as a duplicate of this bug. ***
I just added libsdl-1.2.6-r2.ebuild to CVS. Please try it out and see if it makes a difference for you. Thanks.
I just tried, but I couldn't install it. root # emerge libsdl -u Calculating dependencies ...done! >>> emerge (1 of 1) media-libs/libsdl-1.2.6-r2 to / >>> md5 src_uri ;-) SDL-1.2.6.tar.gz >>> Unpacking source... >>> Unpacking SDL-1.2.6.tar.gz to /var/tmp/portage/libsdl-1.2.6-r2/work patching file src/video/xbios/SDL_xbios.c Hunk #1 FAILED at 22. 1 out of 2 hunks FAILED -- saving rejects to file src/video/xbios/SDL_xbios.c.rej patching file src/video/xbios/SDL_xbios.c Hunk #1 FAILED at 22. 1 out of 2 hunks FAILED -- saving rejects to file src/video/xbios/SDL_xbios.c.rej patching file src/video/x11/SDL_x11modes.c Hunk #1 FAILED at 22. 1 out of 2 hunks FAILED -- saving rejects to file src/video/x11/SDL_x11modes.c.rej !!! ERROR: media-libs/libsdl-1.2.6-r2 failed. !!! Function src_unpack, Line 37, Exitcode 1 !!! patch failed
Yeah, I dorked up the patch with RCS ids. I've fixed it in CVS, so please resync and try it again. Thanks.
Yep, that seems to work. Thanks for the effort.