Live data from Hacker News

Mach-O Tricks [pdf]

iokit.racing

1–2 of 2 posts

Re: Mach-O Tricks [pdf]

#2
Another interesting fact: Mach-O also specifies "fat" or universal binaries, which are just a packed collection of Mach-O binaries with a special header and magic value (CAFEBABE for big-endian, like a Java classfile). The loader reads this special header, seeks to the right cpu(sub)type, and the rest is the same as a "thin" Mach-O.

Source: I wrote a Mach-O parser for the Homebrew project[1].

[1]: https://github.com/Homebrew/ruby-macho