SDLgears

At default size SDLgears runs 100 fps faster… however it appears to
just jidder back and forth. When full screen gears and SDLgears run at
the same frame rate but SDL kills my mouse… extremely laggy.

Guys,
I have an enquiry to make, regarding SDLgears.

I’m trying to cross-compile this program to run on another architecture.
So far, I have the source code and any other sources I need (for SDLgears)

But, when I passed this command
’ldd SDLgears’
to bash, I get a list of shared libraries (shown below).

$ ldd SDLgears
linux-gate.so.1 => (0x0042c000)
libSDL-1.2.so.0 => /usr/lib/libSDL-1.2.so.0 (0x004e6000)
libGL.so.1 => /usr/lib/libGL.so.1 (0x00471000)
libc.so.6 => /lib/libc.so.6 (0x00101000)
libm.so.6 => /lib/libm.so.6 (0x00dd2000)
libdl.so.2 => /lib/libdl.so.2 (0x0026c000)
libpthread.so.0 => /lib/libpthread.so.0 (0x00273000)
libX11.so.6 => /usr/lib/libX11.so.6 (0x052e0000)
libXext.so.6 => /usr/lib/libXext.so.6 (0x053e3000)
libXxf86vm.so.1 => /usr/lib/libXxf86vm.so.1 (0x00610000)
libXdamage.so.1 => /usr/lib/libXdamage.so.1 (0x00773000)
libXfixes.so.3 => /usr/lib/libXfixes.so.3 (0x05726000)
libdrm.so.2 => /usr/lib/libdrm.so.2 (0x0040b000)
/lib/ld-linux.so.2 (0x002d9000)
libxcb-xlib.so.0 => /usr/lib/libxcb-xlib.so.0 (0x002b1000)
libxcb.so.1 => /usr/lib/libxcb.so.1 (0x002b5000)
libXau.so.6 => /usr/lib/libXau.so.6 (0x002ac000)
libXdmcp.so.6 => /usr/lib/libXdmcp.so.6 (0x002a4000)

My question is, ‘Are these the libraries SDLgears need, so it could run?’

I’m saying this because, if they are the libraries it needs, would that mean
I have to cross-compile them all to Sparc version, right?

All Suggestions, welcomed

Thanks in advance.

Most of those libraries are dependencies that SDL has, or picks up
during compilation. Some of them are optional, and are detected at
compile time.

Compile SDL for the target platform, then it will only end up with the
libraries that are required on that platform. Once you compile SDL,
then compile your app.

-RayOn Tue, Mar 10, 2009 at 6:22 AM, Mike Mike wrote:

Guys,
? I have an enquiry to make, regarding SDLgears.

? I’m trying to cross-compile this program to run on another architecture.
? So far, I have the source code and any other sources I need (for SDLgears)

But, when I passed this command
?? ‘ldd SDLgears’
?to bash, I get a list of shared libraries (shown below).

$ ldd SDLgears
??? linux-gate.so.1 =>? (0x0042c000)
??? libSDL-1.2.so.0 => /usr/lib/libSDL-1.2.so.0 (0x004e6000)
??? libGL.so.1 => /usr/lib/libGL.so.1 (0x00471000)
??? libc.so.6 => /lib/libc.so.6 (0x00101000)
??? libm.so.6 => /lib/libm.so.6 (0x00dd2000)
??? libdl.so.2 => /lib/libdl.so.2 (0x0026c000)
??? libpthread.so.0 => /lib/libpthread.so.0 (0x00273000)
??? libX11.so.6 => /usr/lib/libX11.so.6 (0x052e0000)
??? libXext.so.6 => /usr/lib/libXext.so.6 (0x053e3000)
??? libXxf86vm.so.1 => /usr/lib/libXxf86vm.so.1 (0x00610000)
??? libXdamage.so.1 => /usr/lib/libXdamage.so.1 (0x00773000)
??? libXfixes.so.3 => /usr/lib/libXfixes.so.3 (0x05726000)
??? libdrm.so.2 => /usr/lib/libdrm.so.2 (0x0040b000)
??? /lib/ld-linux.so.2 (0x002d9000)
??? libxcb-xlib.so.0 => /usr/lib/libxcb-xlib.so.0 (0x002b1000)
??? libxcb.so.1 => /usr/lib/libxcb.so.1 (0x002b5000)
??? libXau.so.6 => /usr/lib/libXau.so.6 (0x002ac000)
??? libXdmcp.so.6 => /usr/lib/libXdmcp.so.6 (0x002a4000)

My question is, ‘Are these the libraries SDLgears need, so it could run?’

I’m saying this because, if they are the libraries it needs, would that mean
I have to cross-compile them all to Sparc version, right?

All Suggestions, welcomed

Thanks in advance.


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

$ ldd SDLgears
linux-gate.so.1 => (0x0042c000)
libSDL-1.2.so.0 => /usr/lib/libSDL-1.2.so.0 (0x004e6000)
libGL.so.1 => /usr/lib/libGL.so.1 (0x00471000)
libc.so.6 => /lib/libc.so.6 (0x00101000)
libm.so.6 => /lib/libm.so.6 (0x00dd2000)
libdl.so.2 => /lib/libdl.so.2 (0x0026c000)
libpthread.so.0 => /lib/libpthread.so.0 (0x00273000)
libX11.so.6 => /usr/lib/libX11.so.6 (0x052e0000)
libXext.so.6 => /usr/lib/libXext.so.6 (0x053e3000)
libXxf86vm.so.1 => /usr/lib/libXxf86vm.so.1 (0x00610000)
libXdamage.so.1 => /usr/lib/libXdamage.so.1 (0x00773000)
libXfixes.so.3 => /usr/lib/libXfixes.so.3 (0x05726000)
libdrm.so.2 => /usr/lib/libdrm.so.2 (0x0040b000)
/lib/ld-linux.so.2 (0x002d9000)
libxcb-xlib.so.0 => /usr/lib/libxcb-xlib.so.0 (0x002b1000)
libxcb.so.1 => /usr/lib/libxcb.so.1 (0x002b5000)
libXau.so.6 => /usr/lib/libXau.so.6 (0x002ac000)
libXdmcp.so.6 => /usr/lib/libXdmcp.so.6 (0x002a4000)

My question is, ‘Are these the libraries SDLgears need, so it could
run?’

Well, it depends. On linux, yes. On a different system not necessarily,
Anything including and below libX11.so are X Window related things, if
SDL is using the frame buffer, then you don’t need them. Libpthread is
the POSIX multi-threading library, SDL uses threads so chances are that
you need that. libGL is, if I’m not mistaken, the OpenGL (i.e. 3D)
library, you need that because gears uses OpenGL but it is, as far as I
know, not needed for 2D SDL. I don’t know if SDL depends on libm (the
math library), I doubt it, but OpenGL does use it. If SDL proper
doesn’t need that, then you can get rid of that too. Of course you need
libc. Don’t remember what libdl does, unless it’s the dynamic loader,
in which case if you have some OS on your system that supports dynamic
loadimg, you already have it, if your system is based on static
linking, then you don’t need it. I wouldn’t have a clue what linux-gate
does but I’d assume that it’s a linux specific thing.

I’m saying this because, if they are the libraries it needs, would
that mean I have to cross-compile them all to Sparc version, right?

If you run some unix-ish OS on the target, then these should be there
already. If you run on something else, then cross-compiling is not that
simple, compiling the whole X11 suite on a non-unix architecture is far
from trivial but most likely you do not need it at all. The POSIX
thread lib is an issue, but most embedded OS-es come with a POSIX
compatibility layer.

Zoltan