I wrote this little tool when I experimented with creating my own SDK (called PSn00bSDK) using the latest GCC toolchain to produce PlayStation executables as PSXSDK's elf2exe never seemed to work for me. Plus it didn't really look like a good converter to me judging by its source code which simply runs objdump and captures its output.
elf2x does proper conversion as it extracts relevant sections straight from the ELF file itself. The converter is also aware of the ELF file's load location allowing control of where the executable will be loaded to.
You may need to modify your makefile for your executable to come out properly with this converter which is just a simple matter of adding a -Ttext parameter which is equivalent to the -Xo parameter in the official SDK's ccpsx compiler (which is based on GCC 2.7.2 or 2.8.1).
Code: Select all
mipsel-unknown-elf-ld -Ttext=0x80010000 main.o -o myprog.elf
mipsel-unknown-elf-gcc -Wl,-Ttext=0x80010000 main.o -o myprog.elf
You do not have the required permissions to view the files attached to this post.
Please don't forget to include my name if you share my work around. Credit where it is due.
Dev. Console: SCPH-7000 with SCPH-7501 ROM, MM3, PAL color fix, Direct AV ports, DB-9 port for Serial I/O, and a Xplorer FX with Caetla 0.35.
DTL-H2000 PC: Dell Optiplex GX110, Windows 98SE & Windows XP, Pentium III 933MHz, 384MB SDRAM, ATI Radeon 7000 VE 64MB, Soundblaster Audigy, 40GB Seagate HDD, Hitachi Lite-on CD-RW Drive, ZIP 250 and 3.5" Floppy.