well I try to port my SDL stuff to linux, and I install the sdl-devel rpm,
then when I got to compiler my programs I get a mass load of linker errors
I run this command
gcc main.c -Os -std=c99 -otrainme -L/usr/X11R6/lib -I/usr/include/SDL -D_REENTRANT -L/usr/lib -Wl,-rpath,/usr/lib -lSDL -lpthread
then I get this output:
: undefined reference to `XFree''
/usr/lib/libSDL.a(SDL_x11wm.o)(.text+0x9ee): In function `X11_SetCaption'':
: undefined reference to `XSync''
/usr/lib/libSDL.a(SDL_x11wm.o)(.text+0xa40): In function `X11_IconifyWindow'':
: undefined reference to `XIconifyWindow''
/usr/lib/libSDL.a(SDL_x11wm.o)(.text+0xa56): In function `X11_IconifyWindow'':
: undefined reference to `XSync''
/usr/lib/libSDL.a(SDL_x11wm.o)(.text+0xabe): In function `X11_GrabInputNoLock'':
: undefined reference to `XUngrabPointer''
/usr/lib/libSDL.a(SDL_x11wm.o)(.text+0xad2): In function `X11_GrabInputNoLock'':
: undefined reference to `XUngrabKeyboard''
/usr/lib/libSDL.a(SDL_x11wm.o)(.text+0xaef): In function `X11_GrabInputNoLock'':
: undefined reference to `XUngrabPointer''
/usr/lib/libSDL.a(SDL_x11wm.o)(.text+0xb24): In function `X11_GrabInputNoLock'':
: undefined reference to `XGrabPointer''
/usr/lib/libSDL.a(SDL_x11wm.o)(.text+0xb49): In function `X11_GrabInputNoLock'':
: undefined reference to `XGrabKeyboard''
/usr/lib/libSDL.a(SDL_x11wm.o)(.text+0xb6d): In function `X11_GrabInputNoLock'':
: undefined reference to `XRaiseWindow''
/usr/lib/libSDL.a(SDL_x11wm.o)(.text+0xb93): In function `X11_GrabInputNoLock'':
: undefined reference to `XSync''
/usr/lib/libSDL.a(SDL_x11wm.o)(.text+0xc32): In function `unlock_display'':
: undefined reference to `XSync''
/usr/lib/libSDL.a(SDL_x11yuv.o)(.text+0x274): In function `X11_CreateYUVOverlay'':
: undefined reference to `XFree''
/usr/lib/libSDL.a(SDL_x11yuv.o)(.text+0x403): In function `X11_CreateYUVOverlay'':
: undefined reference to `XFree''
/usr/lib/libSDL.a(SDL_x11yuv.o)(.text+0x4bc): In function `X11_CreateYUVOverlay'':
: undefined reference to `XSetErrorHandler''
/usr/lib/libSDL.a(SDL_x11yuv.o)(.text+0x4db): In function `X11_CreateYUVOverlay'':
: undefined reference to `XShmAttach''
/usr/lib/libSDL.a(SDL_x11yuv.o)(.text+0x4f5): In function `X11_CreateYUVOverlay'':
: undefined reference to `XSync''
/usr/lib/libSDL.a(SDL_x11yuv.o)(.text+0x504): In function `X11_CreateYUVOverlay'':
: undefined reference to `XSetErrorHandler''
/usr/lib/libSDL.a(SDL_x11yuv.o)(.text+0x56b): In function `X11_CreateYUVOverlay'':
: undefined reference to `XFree''
/usr/lib/libSDL.a(SDL_x11yuv.o)(.text+0x5dc): In function `X11_CreateYUVOverlay'':
: undefined reference to `XFree''
/usr/lib/libSDL.a(SDL_x11yuv.o)(.text+0x7d3): In function `X11_DisplayYUVOverlay'':
: undefined reference to `XSync''
/usr/lib/libSDL.a(SDL_x11yuv.o)(.text+0x83e): In function `X11_FreeYUVOverlay'':
: undefined reference to `XShmDetach''
/usr/lib/libSDL.a(SDL_x11yuv.o)(.text+0x85d): In function `X11_FreeYUVOverlay'':
: undefined reference to `XFree''
/usr/lib/libSDL.a(Xv.o)(.text+0x25): In function `xv_close_display'':
: undefined reference to `XextRemoveDisplay''
/usr/lib/libSDL.a(Xv.o)(.text+0x54): In function `xv_find_display'':
: undefined reference to `XextCreateExtension''
/usr/lib/libSDL.a(Xv.o)(.text+0x72): In function `xv_find_display'':
: undefined reference to `XextFindDisplay''
/usr/lib/libSDL.a(Xv.o)(.text+0x9b): In function `xv_find_display'':
: undefined reference to `XextAddDisplay''
/usr/lib/libSDL.a(Xv.o)(.text+0x112): In function `xv_error_string'':
: undefined reference to `XGetErrorDatabaseText''
/usr/lib/libSDL.a(Xv.o)(.text+0x167): In function `SDL_XvQueryExtension'':
: undefined reference to `XMissingExtension''
/usr/lib/libSDL.a(Xv.o)(.text+0x19a): In function `SDL_XvQueryExtension'':
: undefined reference to `_XFlush''
/usr/lib/libSDL.a(Xv.o)(.text+0x1ca): In function `SDL_XvQueryExtension'':
: undefined reference to `_XReply''
/usr/lib/libSDL.a(Xv.o)(.text+0x2a6): In function `SDL_XvQueryAdaptors'':
: undefined reference to `XMissingExtension''
/usr/lib/libSDL.a(Xv.o)(.text+0x2df): In function `SDL_XvQueryAdaptors'':
: undefined reference to `_XFlush''
/usr/lib/libSDL.a(Xv.o)(.text+0x31e): In function `SDL_XvQueryAdaptors'':
: undefined reference to `_XReply''
/usr/lib/libSDL.a(Xv.o)(.text+0x394): In function `SDL_XvQueryAdaptors'':
: undefined reference to `_XRead''
/usr/lib/libSDL.a(Xv.o)(.text+0x682): In function `SDL_XvQueryEncodings'':
: undefined reference to `XMissingExtension''
/usr/lib/libSDL.a(Xv.o)(.text+0x6bb): In function `SDL_XvQueryEncodings'':
: undefined reference to `_XFlush''
/usr/lib/libSDL.a(Xv.o)(.text+0x6fa): In function `SDL_XvQueryEncodings'':
: undefined reference to `_XReply''