$ uname -a
Darwin xxx.local 9.6.0 Darwin Kernel Version 9.6.0: Mon Nov 24
17:37:00 PST 2008; root:xnu-1228.9.59~1/RELEASE_I386 i386 i386
MacBookPro5,1 Darwin
The gcc patch is fine. The binutils patches will break setups using a cross compiler to build the ps2 toolchain for other hosts. They won't affect anything when compiling the ps2 toolchain with a native toolchain, unless the native toolchain is broken as the test checking for that is commented.
Thanks for the patch. Using it I managed to install the toolchain on macos 10.5.5. But I had to make a few other changes for it to work.
The problem was the three configure scripts for binutils2.14/bfd binutils2.14/binutils and binutils2.14/opcodes. They all stop with an error saying the native macos gcc compiler does not work. This has to do with the way the configure scripts figure out the suffix for executables (for example .exe). To find the suffix (variable ac_cv_exeext) the scripts run gcc on conftest.c and detect what files are created with name conftest.*. Files ending with .c .o .obj .ilk .pdb are ignored. Seeing the newly created directory conftest.dSYM the configure scripts think that this is the exefile and that .dSYM is the suffix. This causes trouble later when the script tries to compile a file with that name which it cannot since there already is a directory with that name. One solution to the problem is to add .dSYM to the list of endings that should be ignored. This requires change of 2-3 lines in each of the three configure scripts.
I have no experience in making patches, so I thought I would just write this comment here to help others with the same problem.
The GNU_FTP variable must also be set for the patch to work.
I saw a patch that did that in the PSP forums for the psp toolchain as well. I think gcc still appended the .dSYM suffix to the exectuables during the compile or install phase, though, since they needed to be stripped off afterwards. Would doing