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

macho: handle -headerpad and -headerpad_max_install_names #11929

Merged
merged 4 commits into from
Jun 25, 2022

Conversation

kubkon
Copy link
Member

@kubkon kubkon commented Jun 24, 2022

Tweaks link-tests and specifically, refactors and pulls MatchAction and ComputeEqAction into a single Action struct with two parsers attached to it fn match(...) and fn computeCmp(...). The former is as it was, however, the latter now generalises the concept of ComputeEqAction by deferring parsing until we actually execute the test (fn make(...)), and permitting comparing against either an extracted variable or a literal (currently only u64) and allowing for any comparison operator of type std.math.CompareOperator.

cc @Luukdegram due to the above.

@kubkon kubkon changed the title macho: handle -headerpad_size and -headerpad_max_install_names macho: handle -headerpad and -headerpad_max_install_names Jun 25, 2022
@kubkon kubkon marked this pull request as ready for review June 25, 2022 08:45
@Luukdegram
Copy link
Member

I like the changes to the linker test structure 👍

kubkon added 4 commits June 25, 2022 17:56
Includes both traditiona and incremental codepaths with one caveat that
in incremental case, the requested size cannot be smaller than the
default padding size due to prealloc required due to incremental nature
of linking.

Also parse `-headerpad_max_install_names`, however, not actionable just yet -
missing implementation.
@kubkon kubkon force-pushed the headerpad_max_install_names branch from 5011855 to 589bf67 Compare June 25, 2022 16:07
@kubkon kubkon merged commit 76b28ed into master Jun 25, 2022
@kubkon kubkon deleted the headerpad_max_install_names branch June 25, 2022 19:16
src/main.zig Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants