Skip to content

Support for newer load commands #2

@jpstotz

Description

@jpstotz

When I look into the source code the load command definitions seem to be a bit old, the latest LC is 0x30 where dyld already knows up to 0x34:
https://opensource.apple.com/source/cctools/cctools-927.0.2/include/mach-o/loader.h.auto.html

#define LC_NOTE 0x31 /* arbitrary data included within a Mach-O file */
#define LC_BUILD_VERSION 0x32 /* build for platform min OS version */
#define LC_DYLD_EXPORTS_TRIE (0x33 | LC_REQ_DYLD) /* used with linkedit_data_command, payload is trie */
#define LC_DYLD_CHAINED_FIXUPS (0x34 | LC_REQ_DYLD) /* used with linkedit_data_command */

The latter two replace starting with iOS15 LC_DYLD_INFO/LC_DYLD_INFO_ONLY
https://www.emergetools.com/blog/posts/iOS15LaunchTime

Sample app with LC_DYLD_EXPORTS_TRIE and LC_DYLD_CHAINED_FIXUPS:
nslogtest2.zip
e

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions