Issue when linking libc

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

Moderators: cheriff, TyRaNiD

Post Reply
User avatar
Shazz
Posts: 244
Joined: Tue Aug 31, 2004 11:42 pm
Location: Somewhere over the rainbow
Contact:

Issue when linking libc

Post by Shazz »

my pspsdk is the revision 772 (24/07/05)

when linking previous program which compiled/linked successfully:

Code: Select all

/usr/local/pspdev/lib/gcc/psp/4.0.0/../../../../psp/lib/libc.a(abort.o): In function `abort':
../../../../../newlib/libc/stdlib/abort.c:63: undefined reference to `_exit'
/usr/local/pspdev/lib/gcc/psp/4.0.0/../../../../psp/lib/libc.a(exit.o): In function `exit':
../../../../../newlib/libc/stdlib/exit.c:65: undefined reference to `_exit'
/usr/local/pspdev/lib/gcc/psp/4.0.0/../../../../psp/lib/libc.a(fstatr.o): In function `_fstat_r':
../../../../../newlib/libc/reent/fstatr.c:62: undefined reference to `_fstat'
/usr/local/pspdev/lib/gcc/psp/4.0.0/../../../../psp/lib/libc.a(makebuf.o): In function `__smakebuf':
../../../../../newlib/libc/stdio/makebuf.c:96: undefined reference to `isatty'
/usr/local/pspdev/lib/gcc/psp/4.0.0/../../../../psp/lib/libc.a(openr.o): In function `_open_r':
../../../../../newlib/libc/reent/openr.c:59: undefined reference to `_open'
/usr/local/pspdev/lib/gcc/psp/4.0.0/../../../../psp/lib/libc.a(sbrkr.o): In function `_sbrk_r':
../../../../../newlib/libc/reent/sbrkr.c:60: undefined reference to `_sbrk'
/usr/local/pspdev/lib/gcc/psp/4.0.0/../../../../psp/lib/libc.a(signalr.o): In function `_kill_r':
../../../../../newlib/libc/reent/signalr.c:61: undefined reference to `_kill'
/usr/local/pspdev/lib/gcc/psp/4.0.0/../../../../psp/lib/libc.a(signalr.o): In function `_getpid_r':
../../../../../newlib/libc/reent/signalr.c:96: undefined reference to `_getpid'
/usr/local/pspdev/lib/gcc/psp/4.0.0/../../../../psp/lib/libc.a(writer.o): In function `_write_r':
../../../../../newlib/libc/reent/writer.c:58: undefined reference to `_write'
/usr/local/pspdev/lib/gcc/psp/4.0.0/../../../../psp/lib/libc.a(closer.o): In function `_close_r':
../../../../../newlib/libc/reent/closer.c:53: undefined reference to `_close'
/usr/local/pspdev/lib/gcc/psp/4.0.0/../../../../psp/lib/libc.a(lseekr.o): In function `_lseek_r':
../../../../../newlib/libc/reent/lseekr.c:58: undefined reference to `_lseek'
/usr/local/pspdev/lib/gcc/psp/4.0.0/../../../../psp/lib/libc.a(readr.o): In function `_read_r':
../../../../../newlib/libc/reent/readr.c:58: undefined reference to `_read'
collect2: ld returned 1 exit status
Is it due to the toolchain/newlib version ? should I recompile the toolchain from the last svn revision ?
- TiTAN Art Division -
http://www.titandemo.org
weak
Posts: 114
Joined: Thu Jan 13, 2005 8:31 pm
Location: Vienna, Austria

Post by weak »

yep, update toolchain/sdk.
mrbrown
Site Admin
Posts: 1537
Joined: Sat Jan 17, 2004 11:24 am

Post by mrbrown »

If you're using the bleeding edge Subversion toolchain, and you get undefined references that you haven't seen before you should always update the toolchain (from Subversion) before rebuilding PSPSDK.
User avatar
Shazz
Posts: 244
Joined: Tue Aug 31, 2004 11:42 pm
Location: Somewhere over the rainbow
Contact:

Post by Shazz »

It takes about 10hours on my laptop... so I try to avoid rebuilding it too often ;-) (else my wife screams as the laptop is slow...) eh eh

Eh eh..that's life.... :D
- TiTAN Art Division -
http://www.titandemo.org
mrbrown
Site Admin
Posts: 1537
Joined: Sat Jan 17, 2004 11:24 am

Post by mrbrown »

Shazz wrote:It takes about 10hours on my laptop... so I try to avoid rebuilding it too often ;-) (else my wife screams as the laptop is slow...) eh eh

Eh eh..that's life.... :D
Sorry to hear that ... I am supposed to find the time to get everyting built into a nice NSIS package ... heh, there is just too much crap going on.
Post Reply