some trouble with libmad [resolved]

Discuss the development of new homebrew software, tools and libraries.

Moderators: cheriff, TyRaNiD

Post Reply
sturatt
Posts: 46
Joined: Thu Jul 13, 2006 4:21 pm

some trouble with libmad [resolved]

Post by sturatt »

Im trying to get libmad installed, but whenever i try to compile with it i get these errors

Code: Select all

Stuart@water ~/projects/DirReadExample
$ make kxploit
psp-gcc -I. -I/usr/local/pspdev/psp/sdk/include -O2 -G0 -Wall  -L. -L/usr/local/
pspdev/psp/sdk/lib   main.o mp3.o stuFunctions.o mp3player.o -lpspgu -lpng -lz -
lm -lstdc++ -lpspaudio -lpspaudiolib -lpsppower -lmad -lpspdebug -lpspdisplay -l
pspge -lpspctrl -lpspsdk -lc -lpspnet -lpspnet_inet -lpspnet_apctl -lpspnet_reso
lver -lpsputility -lpspuser -lpspkernel -o DirectoryReading.elf
/usr/local/pspdev/psp/sdk/lib/libpspaudiolib.a(pspaudiolib.o): In function `pspA
udioOutBlocking':
/tmp/pspdev/pspsdk/src/audio/pspaudiolib.c:55: undefined reference to `sceAudioO
utputPannedBlocking'
/usr/local/pspdev/psp/sdk/lib/libpspaudiolib.a(pspaudiolib.o): In function `pspA
udioInit':
/tmp/pspdev/pspsdk/src/audio/pspaudiolib.c:105: undefined reference to `sceAudio
ChReserve'
/tmp/pspdev/pspsdk/src/audio/pspaudiolib.c:111: undefined reference to `sceAudio
ChRelease'
/usr/local/pspdev/psp/sdk/lib/libpspaudiolib.a(pspaudiolib.o): In function `pspA
udioEnd':
/tmp/pspdev/pspsdk/src/audio/pspaudiolib.c:171: undefined reference to `sceAudio
ChRelease'
collect2: ld returned 1 exit status
make: *** [DirectoryReading.elf] Error 1
can anyone help me out with these?
Last edited by sturatt on Sun Jul 16, 2006 7:52 pm, edited 1 time in total.
PeterM
Posts: 125
Joined: Sat Dec 31, 2005 7:25 pm
Location: Edinburgh, UK
Contact:

Post by PeterM »

Try specifying your libraries in a different order when linking - try putting -lpspaudiolib before -lpspaudio?

Hopefully it'll work...
FreePlay
Posts: 71
Joined: Wed Jan 04, 2006 6:53 pm
Location: Schenectady, New York, USA

Post by FreePlay »

And if that doesn't work, there's always the fallback option of making sure you have the latest version of the SDK installed.
sturatt
Posts: 46
Joined: Thu Jul 13, 2006 4:21 pm

Post by sturatt »

well that did it, i had no idea that those needed to be put in a certain order. thanks for all the help guys, i appreciate it.
PeterM
Posts: 125
Joined: Sat Dec 31, 2005 7:25 pm
Location: Edinburgh, UK
Contact:

Post by PeterM »

It's to do with how the linker sorts out dependencies.

libpspaudiolib depends on libpspaudio, so it needs to go first. Which is a bit silly, but hey...
Post Reply