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

Symbol versioning support #1209

Merged
merged 9 commits into from
Dec 31, 2024
Merged

Conversation

qookei
Copy link
Member

@qookei qookei commented Dec 27, 2024

There's some minor TODOs left in the code (handling weak versions and figuring out what to do about VERDEF dependency names), but this is sufficient to fix #1208, and the TODOs aren't a problem when booting Managarm (which has plenty of libraries with versioned symbols).

Closes #1208.

Copy link
Member

@64 64 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with a few nits

options/rtld/generic/linker.cpp Outdated Show resolved Hide resolved
options/rtld/generic/linker.cpp Outdated Show resolved Hide resolved
options/rtld/generic/linker.cpp Show resolved Hide resolved
options/rtld/generic/linker.cpp Outdated Show resolved Hide resolved
options/rtld/generic/linker.cpp Show resolved Hide resolved
Copy link
Member

@Dennisbonke Dennisbonke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

All resolution functions now optionally take the version of the symbol
to resolve to. Specifying no version means the default is picked (for
dlsym etc).
Some compiler optimizations done via builtins can cause the tests to
fail (e.g. compiler optimizes out failing call to calloc, and assumes
that it succeeds).
@Dennisbonke Dennisbonke added this pull request to the merge queue Dec 31, 2024
Merged via the queue into managarm:master with commit df2cf06 Dec 31, 2024
38 of 39 checks passed
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.

Symbol versioning is unsupported
4 participants