• Register

How to distinguish 68k and PPC executables on classic Macintoshes?

+1 vote
5,757 views
When getting a binary for a classic Macintosh operating system (up until version 9), how to distinguish for which processor architecture the binary was made?
asked Mar 26, 2015 by despens (990 points)

1 Answer

+2 votes
 
Best answer

PowerPC executables store their code in the data fork, while 68k executables store their code in the resource fork. Examine the first 12 bytes of the data fork for the ASCII Joy!peffpwpc to determine the presence of PowerPC executable code. Examine the resource fork for the presence of a CODE resource to determine the presence of m68k executable code. Note that many MacOS executables are "fat binaries" which contain code for both architectures; these can be identified by the presence of a cfrg resource with an ID of 0.

Source: https://support.apple.com/kb/TA21606

answered Mar 26, 2015 by AprilArcus (480 points)
selected Apr 30, 2015 by despens
...