Executable formats
Mach-O load-command sizes
Check command-size alignment and calculate ncmds and sizeofcmds.
Your inputs
Start with an exampleYour result
Example resultAa — A small example of your colors.
How it works
Every command includes its 8-byte base fields. Sum cmdsize values and add the 28-byte or 32-byte Mach header.
Two 64-bit commands of 24 and 56 bytes give ncmds 2, sizeofcmds 80 and 112 bytes including the header.
Limits
Sizes must satisfy the selected ABI alignment. Command-specific fields and the rest of the file are not inspected.