Why can't I find any official documentation for the file format?

I've seen this link a lot, but it seems that they've taken whatever used to be there down.

The best I could find was some blog posts and this mirror of the older documentation on github. This information still seems to be accurate, but why did Apple take this down? Has the documentation been moved somewhere? Have they deprecated some of the information in that document or perhaps the file format as a whole?

Edit I have been looking into this a bit more, and it seems like the mirrored documentation isn't actually completely up to do date. For instance, when compiling a source file with gcc -c the resulting object file includes a load command of type LC_BUILD_VERSION. This command type is not present in the documentation, but the corresponding data structure is present in /usr/include/mach/loader.h (which is now present in 10.14 only when installed from a package). It looks like there are more load commands that aren't documented as well.

1 Answer 1


With my previous comment, it appears that the loader.h file located at https://opensource.apple.com/source/xnu/xnu-4903.221.2/EXTERNAL_HEADERS/mach-o/loader.h.auto.html

IS the official documentation. Near the top it says

 * This file describes the format of mach object files.

And the comments in the file are more extensive than I realized.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .