As you may know, Macs are available in 2 architectures, PowerPC
and Intel, and up until recently Apple shipped a dynamic translator called Rosetta with their Intel Macs, so PowerPC programs will still run (albeit a bit slower) on both architectures. However, Rosetta was made optional in 10.6 and dropped completely in 10.7, which means now we HAVE to compile Intel.
It's possible to compile a "Universal binary" that contains both
PowerPC and Intel versions of the code. The problem with doing this in eSpeak is that eSpeak expects different phoneme data files depending on the CPU's endianness. Therefore, I patched synthdata.cpp as follows, to make it read the phoneme data from different files depending on the endianness:
(An alternative approach would be to incorporate the
platforms/big_endian logic into the eSpeak runtime, which is probably OK on a Mac as the CPU is quite fast.)
Attached is an eSpeak 1.45.04 compiled as a "Universal binary"
for i386 and PPC, with both the big-endian and little-endian phoneme data files included and with the above patch to cause it to read from the appropriate file depending on which architecture it's running on. I've tested it on both architectures and it works on both. As the university is just about to upgrade all their Macs to 10.7 (which will not have Rosetta), this is probably the last time I'll be able to test any PPC code, so I thought I'd better get it in while I can!