First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 148186
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Gentoo Games <games@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Rabinath <contact@rabinath.org>
Add CC:
CC:
Remove selected CCs
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 148186 depends on: Show dependency tree
Show dependency graph
Bug 148186 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2006-09-19 05:54 0000
Since libSDL-1.2.11 all programs using SDL fail to compile complaining about an
unresolved refetence to 'BlitRGBtoRGBPixelAlphaMMX3DNOW'. In file
src/video/SDL_blit_A.c lines 2817 - 2829 there's an autodetection for my CPU's
capabilities:
                {
                        if(SDL_Has3DNow())
                                return BlitRGBtoRGBPixelAlphaMMX3DNOW;
                        if(SDL_HasMMX())
                                return BlitRGBtoRGBPixelAlphaMMX;
                }
where 'if(SDL_Has3DNow())' seems to return true, which is clearly wrong: cat
/proc/cpuinfo | grep ^flags returns 'fpu vme de pse tsc msr pae mce cx8 apic
sep mtrr pge mca cmov pat clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx
constant_tsc pni monitor vmx est tm2 xtpr'
Hacking the code to always return the non-3dnow function
BlitRGBtoRGBPixelAlphaMMX solved my errors.
There's also some other guy having the same problem:
http://forums.gentoo.org/viewtopic-p-3588281.html

------- Comment #1 From SpanKY 2006-09-19 13:33:18 0000 -------
*** Bug 144828 has been marked as a duplicate of this bug. ***

------- Comment #2 From SpanKY 2006-09-19 14:34:51 0000 -------
i'm pretty sure the bug here is that BlitRGBtoRGBPixelAlphaMMX3DNOW is declared
as inline ... it has nothing to do with misdetection of CPU as the failure
you're seeing is at *linktime* and that code is not executed until *runtime*

so try editing src/video/SDL_blit_A.c, go to the definition of
BlitRGBtoRGBPixelAlphaMMX3DNOW(), and remove the 'inline' keyword

------- Comment #3 From Rabinath 2006-09-19 22:56:08 0000 -------
Removing the inline keyword did the job, both sdl-image and quake2-icculus do
emerge now without errors.

------- Comment #4 From SpanKY 2006-09-20 21:00:58 0000 -------
that doesnt really satisfy my curiosity as to why you are seeing this problem

that function is declared static so the symbol should not be exported thus
linking against it shouldnt be a problem ...

can you post: `emerge -pv libsdl`

------- Comment #5 From Rabinath 2006-09-21 03:39:22 0000 -------
[ebuild   R   ] media-libs/libsdl-1.2.11  USE="X aalib alsa esd fbcon libcaca
opengl oss xinerama xv -arts -dga -directfb -ggi -nas -noaudio -noflagstrip
-nojoystick -novideo -svga" 0 kB 

CFLAGS="-O2 -fomit-frame-pointer -march=prescott -pipe"
CXXFLAGS="-O2 -fomit-frame-pointer -march=prescott -pipe
-fvisibility-inlines-hidden"

gcc (GCC) 4.1.1 (Gentoo 4.1.1-r1)

I reemerged it without changes to find out more about it.

# objdump -T libSDL-1.2.so.0.11.0 | fuzzygrep -l3 3DNOW
00011497 g    DF .text  000001ad  Base        SDL_iconv_string
00005fe3 g    DF .text  00000029  Base        SDL_ClearError
00000000      D  *UND*  00000000              BlitRGBtoRGBPixelAlphaMMX3DNOW
0001034c g    DF .text  0000003c  Base        SDL_ReadBE16
00000000      DF *UND*  000001ba  GLIBC_2.1   fclose

------- Comment #6 From SpanKY 2007-03-20 02:39:38 0000 -------
oh well, we'll just call it a day ... no time to investigate this further ;(

First Last Prev Next    No search results available      Search page      Enter new bug