My name is Michael and I've been programming for years, I used to be very much into the PSP development scene. After PSP-Hacks went away I lost touch with the scene and moved to iOS development because getting paid for things appealed to me. I've been missing the PSP scene for a while now so I thought I'd come back to it now. I've chosen this forum because I've noticed that there is a bunch of activity on it, and I've got a sense of respect for this place for reasons unknown to me.
So, yes, hello everybody!
Now on to my actual question.
I've been trying for about a week now to compile the psptoolchain on my installation of OS X Snow Leopard. I always get errors around the part with newlib. Sometimes saying that the program "AS" in my "usr/libexec/gcc/darwin/x86_64/" folder is complaining that it doesn't understand the -G parameter or something else completely remote that nobody seemed to have trouble with but me... I did find people with the error above, and most of the errors that I got, but none of them were solved in a clear way and were so old that I wouldn't get any response from registering an account and asking in the thread.
So I tried to install devkitPSP but I got that same AS error, and then I backed up the AS executable in that directory and replaced it with "psp-as" and renamed it to "AS." Then I had issues with ld not knowing what the "-EL" parameter was, so I figured it was looking in the wrong compiler directories again like it was with AS and I backed up and replaced "usr/bin/ld" with "psp-gcc" and renamed it like with AS. I stopped getting those errors and started getting errors about not finding certain headers or static libraries. So I modified the Build.mak file to search in the directories with those files and now it ALMOST compiles the basic controller sample in the SDK. Here's what I get:
- Code: Select all
MacBook-Pro:basic Computer$ makepsp-gcc -I. -I/usr/local/pspdev/psp/sdk/include -I. -I/usr/local/pspdev/lib/gcc/psp/4.6.2/include -I. -I/usr/local/pspdev/psp/include -O2 -G0 -Wall -D_PSP_FW_VERSION=150 -L. -L/usr/local/pspdev/psp/sdk/lib -L. -L/usr/local/pspdev/psp/lib -L. -L/usr/local/pspdev/lib/gcc/psp/4.6.2/ main.o -lpspdebug -lpspdisplay -lpspge -lpspctrl -lpspsdk -lc -lpspnet -lpspnet_inet -lpspnet_apctl -lpspnet_resolver -lpsputility -lpspuser -lpspkernel -o controller_basic.elf
ld: error: crt0.o: No such file or directory
ld: error: crti.o: No such file or directory
ld: error: crtbegin.o: No such file or directory
ld: error: crtend.o: No such file or directory
ld: error: crtn.o: No such file or directory
make: *** [controller_basic.elf] Error 1
Which is very strange to me, because I added the directories with those files in them to the linker search directories!
Here's the modified lines in build.mak if necessary:
- Code: Select all
# Add in PSPSDK includes and libraries.
INCDIR := $(INCDIR) . $(PSPSDK)/include . $(PSPDEV)/lib/gcc/psp/4.6.2/include . $(PSPDEV)/psp/include
LIBDIR := $(LIBDIR) . $(PSPSDK)/lib . $(PSPDEV)/psp/lib . $(PSPDEV)/lib/gcc/psp/4.6.2/
I know people have compiled the PSPSDK for OS X 10.6.7 before because I've seen it in a few threads, I'm just making some stupid mistake somewhere or missing something. Is there a patched toolchain or a precompiled sdk somewhere or something?
Thanks for any help in advanced!
I do have bootcamp and Windows 7 installed, but I don't fancy switching operating systems and copying all my engine's files when I want to compile it for the PSP rather than OS X or iOS.