Problems With Static Linking


xzakox

Still Fresh
Joined
Jan 16, 2006
Messages
12
Location
Avilés, Asturias, Spain
Website
ladecadence.net
I'm having problems when trying to link statically my programs. I'm cross-compiling from linux-ppc, using GP2XDev toolchain, but before, I used the devKitGP2X with the same results.
The stuff is, when trying to compile my app, I get the following errors:
Code:
[...]
/tmp/ccYCRd4j.o: In function `error':
main.c:(.text+0x650): undefined reference to `TTF_SizeUTF8'
main.c:(.text+0x8c0): undefined reference to `boxRGBA'
main.c:(.text+0x95c): undefined reference to `SDL_UpdateRect'
main.c:(.text+0x96c): undefined reference to `SDL_Flip'
main.c:(.text+0x97c): undefined reference to `SDL_PollEvent'
/tmp/ccYCRd4j.o: In function `main':
main.c:(.text+0xc50): undefined reference to `SDL_Quit'
main.c:(.text+0xc54): undefined reference to `TTF_Quit'
collect2: ld returned 1 exit status
and so on...

i'm passing all the paths and libs to gcc (I think), this is the command I'm using:
Code:
gp2x-gcc -I/usr/local/gp2xdev/include/ -L/usr/local/gp2xdev/lib/ -static -lSDL_ttf -lSDL_gfx -lSDL -lfreetype -lpthread  -lgcc -lc zakosdl.c main.c -o test.gpe

any ideas? what I'm missing?
Tnks, zako.
 
Back
Top