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 

ps2sdk build error

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



Joined: 17 Jan 2004
Posts: 1536

PostPosted: Sat May 29, 2004 5:51 pm    Post subject: ps2sdk build error Reply with quote

I get the following when trying to build ps2sdk from CVS:

Code:
ee-gcc -D_EE -O2 -G0 -Wall   -I/home/mrbrown/cvs/ps2dev/ps2sdk/ee/kernel/include -I/home/mrbrown/cvs/ps2dev/ps2sdk/common/include -Iinclude -DF_SifCheckStatRpc src/sifrpc.c -c -o obj/SifCheckStatRpc.o
ee-gcc -D_EE -O2 -G0 -Wall   -I/home/mrbrown/cvs/ps2dev/ps2sdk/ee/kernel/include -I/home/mrbrown/cvs/ps2dev/ps2sdk/common/include -Iinclude -DF_fio_main src/fileio.c -c -o obj/fio_main.o
src/fileio.c:17:20: string.h: No such file or directory
make[2]: *** [obj/fio_main.o] Error 1
make[2]: Leaving directory `/home/mrbrown/cvs/ps2dev/ps2sdk/ee/kernel'
make[1]: *** [all-kernel] Error 2
make[1]: Leaving directory `/home/mrbrown/cvs/ps2dev/ps2sdk/ee'
make: *** [all-ee] Error 2


Let me guess, everyone who has built ps2sdk has newlib installed? I don't.
Back to top
View user's profile Send private message
ole



Joined: 08 May 2004
Posts: 92
Location: Czech Republic

PostPosted: Sat May 29, 2004 6:05 pm    Post subject: Reply with quote

Uff...
Are PS2SDK sources available to public now? Where?
(I thought there are only on ufo that has restricted accesss)
Back to top
View user's profile Send private message
mrbrown



Joined: 17 Jan 2004
Posts: 1536

PostPosted: Sat May 29, 2004 6:10 pm    Post subject: Reply with quote

So, after adding -I$(PS2SDKSRC)/ee/libc/include to EE_INCS in $(PS2SDKSRC)/ee/Rules.make, I get the following error (with both GCC 2.9ee and 3.22):

Code:
make[2]: Entering directory `/home/mrbrown/cvs/ps2dev/ps2sdk/ee/loader'
ee-gcc -nostartfiles -T/home/mrbrown/cvs/ps2dev/ps2sdk/ee/startup/src/linkfile -L/home/mrbrown/cvs/ps2dev/ps2sdk/ee/kernel/lib -L/home/mrbrown/cvs/ps2dev/ps2sdk/ee/libc/lib -L/home/mrbrown/cvs/ps2dev/ps2sdk/ee/rpc/hdd/lib -L/home/mrbrown/cvs/ps2dev/ps2sdk/ee/rpc/filexio/lib -L/home/mrbrown/cvs/ps2dev/ps2sdk/ee/rpc/poweroff/lib \
        -o bin/loader.elf /home/mrbrown/cvs/ps2dev/ps2sdk/ee/startup/obj/crt0.o obj/loader.o obj/fakehost.o obj/poweroff.o -lkernel -lpoweroff -lhdd -lfileXio -lsyscall -lc -lkernel
/home/mrbrown/cvs/ps2dev/ps2sdk/ee/libc/lib/libc.a(sbrk.o): In function `ps2_sbrk':
src/sbrk.c(.text+0x64): undefined reference to `EndOfHeap'
collect2: ld returned 1 exit status
make[2]: *** [bin/loader.elf] Error 1
make[2]: Leaving directory `/home/mrbrown/cvs/ps2dev/ps2sdk/ee/loader'
make[1]: *** [all-loader] Error 2
make[1]: Leaving directory `/home/mrbrown/cvs/ps2dev/ps2sdk/ee'
make: *** [all-ee] Error 2


Argh. libsyscall.a has always been redundant. Did anyone ever link to it before this change in ps2sdk? Please remove it and move the syscalls back into libkernel.a where they belong. Why was this changed from ps2lib anyway?

And, let me guess, everyone who has built ps2sdk up to this point has been linking with newlib, and not ps2sdk's internal libc?
Back to top
View user's profile Send private message
t0mb0la



Joined: 20 Jan 2004
Posts: 24
Location: Seattle WA, USA

PostPosted: Sun May 30, 2004 7:04 am    Post subject: Reply with quote

I saw the same link error for the first time yesterday, after a CVS update.

I added an extra '-lc' to the EE_LIBS in ps2sdk/ee/loader/Makefile, as the first entry and linking worked.

I am using gcc-3.2.2 in cygwin, which was compiled using ooPo's toolchain scripts, these include newlib as part of the build iirc.

I'm not sure where this linkage weirdness came from. The only update I'd gotten from CVS for ps2sdk was xprintf.c, and as I rule I always 'make clean' at the top level before 'make', esp. for library updates.
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger MSN Messenger
mrbrown



Joined: 17 Jan 2004
Posts: 1536

PostPosted: Sun May 30, 2004 7:38 am    Post subject: Reply with quote

Great. Now printf() uses malloc() internally. Congrats, our libc is as crappy as newlib now.
Back to top
View user's profile Send private message
sjeep



Joined: 17 Jan 2004
Posts: 10
Location: New Zealand

PostPosted: Sun May 30, 2004 8:11 am    Post subject: Reply with quote

Well, why dont you fix it instead of just bitching? :)
Back to top
View user's profile Send private message
Lukasz



Joined: 19 Jan 2004
Posts: 248
Location: Denmark

PostPosted: Sun May 30, 2004 7:51 pm    Post subject: Reply with quote

mrbrown wrote:
Great. Now printf() uses malloc() internally. Congrats, our libc is as crappy as newlib now.


Where does it use malloc() ?

I only see it in mout(), mprintf() & vmprintf() and none of those are built into libc.a because of the #ifdef's. I just keept them there until there is some sort of agreement what to do with functions which weren't in the old xprintf.c source.
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PS2 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