forums.ps2dev.org Forum Index forums.ps2dev.org
Homebrew PS2, PSP & PS3 Development Discussions
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Problem compiling an SDL proggy

 
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development
View previous topic :: View next topic  
Author Message
lpopman



Joined: 28 Mar 2006
Posts: 6

PostPosted: Tue Mar 28, 2006 9:00 am    Post subject: Problem compiling an SDL proggy Reply with quote

Hi Guys,

I'm trying to compile an SDL program using a recent (about a week old) toolchain from the svn.

everything compiles ok, then when it comes to link with libGL it barfs the following:

Code:

/usr/local/pspdev/psp/lib/libGL.a(eglCreateContext.o): In function `eglCreateContext':
/usr/local/pspdev/psp/sdk/trunk/pspgl/eglCreateContext.c:43: undefined reference to `pspvfpu_initcontext'
/usr/local/pspdev/psp/lib/libGL.a(eglDestroyContext.o): In function `eglDestroyContext':
/usr/local/pspdev/psp/sdk/trunk/pspgl/eglDestroyContext.c:42: undefined reference to `pspvfpu_deletecontext'
/usr/local/pspdev/psp/lib/libGL.a(glLoadIdentity.o): In function `glLoadIdentity':
/usr/local/pspdev/psp/sdk/trunk/pspgl/glLoadIdentity.c:23: undefined reference to `pspvfpu_use_matrices'
/usr/local/pspdev/psp/lib/libGL.a(pspgl_context.o): In function `flush_matrix':
/usr/local/pspdev/psp/sdk/trunk/pspgl/pspgl_context.c:108: undefined reference to `pspvfpu_use_matrices'
/usr/local/pspdev/psp/lib/libGL.a(pspgl_matrix.o): In function `__pspgl_matrix_sync':
/usr/local/pspdev/psp/sdk/trunk/pspgl/pspgl_matrix.c:19: undefined reference to `pspvfpu_use_matrices'
/usr/local/pspdev/psp/lib/libGL.a(pspgl_matrix.o): In function `__pspgl_matrix_load':
/usr/local/pspdev/psp/sdk/trunk/pspgl/pspgl_matrix.c:33: undefined reference to `pspvfpu_use_matrices'
/usr/local/pspdev/psp/lib/libGL.a(glMultMatrixf.o): In function `glMultMatrixf':
/usr/local/pspdev/psp/sdk/trunk/pspgl/glMultMatrixf.c:17: undefined reference to `pspvfpu_use_matrices'


I have the following LIBS line:

LIBS += -L/usr/local/pspdev/psp/lib -L/usr/local/pspdev/psp/sdk/lib -lSDLmain -lSDL -lm -lpspvfpu -lGL -lpspdebug -lpspgu -lpspctrl -lpspge -lpspdisplay -lpsphprm -lpspsdk -lpsprtc -lpspaudio -lc -lpspuser -lpspkernel -lpsppower -lpng -lz -lm -lg -lstdc++ -lc -lpsputility -lpng

I even included libpspvfpu incase that might be it, but to no avail... any ideas?
Back to top
View user's profile Send private message
Drakonite
Site Admin


Joined: 17 Jan 2004
Posts: 989

PostPosted: Tue Mar 28, 2006 9:07 am    Post subject: Reply with quote

Linking order can matter, and it looks like that may be the problem here...
If -lpspvfpu is the lib with "pspvfpu_use_matrices" and such, it needs to be after the libs that require it.
_________________
Shoot Pixels Not People!
Makeshift Development
Back to top
View user's profile Send private message Visit poster's website
lpopman



Joined: 28 Mar 2006
Posts: 6

PostPosted: Wed Mar 29, 2006 2:18 am    Post subject: Reply with quote

Thanks man, that sorted it :)

I actually thought that you needed to link stuff like that first to let the later obj's pick up the symbols...ya learn something new every day.

Regards,

Lee
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development All times are GMT + 10 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group