[sdljava-users] Problems compiling in Mac OSX
Status: Beta
Brought to you by:
ivan_ganza
From: Nuno S. <dev...@im...> - 2006-07-08 17:42:54
|
Hi, I'm trying to install sdljava in OSX, so i'm trying to compile from the scratch. When doing that i have the following error: MACKIE:~/Desktop/sdljava-0.9.1/src/sdljava/native lpx$ make gcc -o libsdljava.so SDLAudio_wrap.o SDLEvent_wrap.o SDLMain_wrap.o SDLVideo_wrap.o SDLJoystick_wrap.o SDLCdrom_wrap.o -lSDL /usr/bin/ld: Undefined symbols: _main collect2: ld returned 1 exit status make: *** [libsdljava.so] Error 1 I also had to take an option -shared because the compiler didnt have it. I have libsdl installed and the sdl libraries are in the place i think they should (it was the gentoo emerge to do it) --- /usr/lib/ >>> /usr/lib/libSDL-1.2.0.11.0.dylib >>> /usr/lib/libSDL-1.2.0.dylib -> libSDL-1.2.0.11.0.dylib >>> /usr/lib/libSDL.a >>> /usr/lib/libSDL.dylib -> libSDL-1.2.0.11.0.dylib >>> /usr/lib/libSDL.la >>> /usr/lib/libSDLmain.a I tried to pass a manual path to linker but or i dont know how to do it or it doesnt work MACKIE:~/Desktop/sdljava-0.9.1/src/sdljava/native lpx$ make gcc -o libsdljava.so SDLAudio_wrap.o SDLEvent_wrap.o SDLMain_wrap.o SDLVideo_wrap.o SDLJoystick_wrap.o SDLCdrom_wrap.o -l /usr/lib/SDL /usr/bin/ld: can't locate file for: -l/usr/lib/SDL collect2: ld returned 1 exit status make: *** [libsdljava.so] Error 1 The first thing i tried was to run directly and of course i had the following result, but i dont know what the message really means, can you tell me what it really says? MACKIE:~/Desktop/IAE/Reactiva lpx$ ./corre Native code library failed to load. java.lang.UnsatisfiedLinkError: no sdljava in java.library.path MACKIE:~/Desktop/IAE/Reactiva lpx$ Best regards, Nuno Santos |