Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for dyld_shared_cache files #434

Open
rickmark opened this issue Jan 14, 2022 · 6 comments
Open

Support for dyld_shared_cache files #434

rickmark opened this issue Jan 14, 2022 · 6 comments

Comments

@rickmark
Copy link
Contributor

A pure ruby implementation of these is useful as loose dylibs no longer exist on Apple platforms

@woodruffw
Copy link
Member

That would be interesting, although I want to take care not to make API concessions that get in the way of Homebrew's uses of ruby-macho 🙂

If we can add support without making their usecases more difficult, I'm all for it.

Someone did a partial writeup on the newer shared cache format here: gimli-rs/object#358

@rickmark
Copy link
Contributor Author

rickmark commented Jan 14, 2022 via email

@woodruffw
Copy link
Member

Sounds good!

@rickmark
Copy link
Contributor Author

Started to work through this implementation.

macOS 12 has DSCs that are multi file now, so the plan is to create MachO::DyldSharedCache class which is a collection of 1 or more MachO::DyldSharedCache::DSCFiles. You can then loop over the DSC to get each of the embedded dylibs.

In order to fully emulate the dsc_extractor.bundle behavior we would need to correctly handle the pre-binding by regenerating exports and imports. This seems far easier when a sideband .symbols file is present (it appears to contain the symbolic names that get optimized away by the prebinding)

@github-actions
Copy link

github-actions bot commented Feb 9, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@github-actions github-actions bot added the Stale label Feb 9, 2022
@woodruffw woodruffw removed the Stale label Feb 9, 2022
@github-actions
Copy link

github-actions bot commented Mar 3, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants