-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
julia: stop hardcoding mbedtls sonames. #30061
Conversation
- const libmbedtls = "libmbedtls.so.13" | ||
- const libmbedx509 = "libmbedx509.so.1" | ||
+ const libmbedcrypto = "libmbedcrypto.so" | ||
+ const libmbedtls = "libmbedtls.so" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This only works on Arch because they don't have devel packages. The unversioned sonames are all in our -devel packages, not the normal ones - this solution isn't portable across distros.
For that matter, if they're using dlopen, they should very much care about the soname version: ABI mismatches cause all sorts of bugs. If my understanding of this patch is correct, I am against it. Will look at the upstream bugs to see if I can add anything there.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It works for us as well; I've confirmed things work locally without mbedtls-devel installed. Julia appears to use these variables to generate the symbolic links in /usr/lib/julia
.
❮ ls -l /usr/lib/julia/libmbedcrypto.so
lrwxrwxrwx 1 root root 29 Apr 6 19:03 /usr/lib/julia/libmbedcrypto.so -> /usr/lib64/libmbedcrypto.so.3
EDIT: I clearly have no idea what I'm talking about here, but this patch definitely makes the things that don't currently work work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree that forcing -devel
dependencies just to drop versions from shared libraries is not desirable.
As for dlopen
, the question is how Julia handles these libraries after they are loaded. If the runtime handles the possibility of missing symbols gracefully, maybe this isn't such a big deal. If not, this could be a huge deal.
(For reference, to test the problem this patch fixes, simply run |
When julia 1.6.0 vendors in mbedtls, it uses v2.26.0 which provides a different set of sonames than the version provided by Void. We need to patch where the library sonames are hardcoded to allow julia to properly call into libraries provided by mbedtls. Closes void-linux#29964 See <JuliaLang/julia#40198> for the upstream bug.
13d5fc1
to
1e17244
Compare
Also change to using vendored llvm to reduce maintenance burden from julia depending on versions of llvm which are quickly obsoleted (closes void-linux#30490); this should also fix julia's build being broken on i686. This doesn't address void-linux#29964, and a decision should still be made on whether to accept void-linux#30061. [ci skip] for building llvm
Also change to using vendored llvm to reduce maintenance burden from julia depending on versions of llvm which are quickly obsoleted (closes void-linux#30490); this should also fix julia's build being broken on i686. When julia 1.6.0 vendors in mbedtls, it uses v2.26.0 which provides a different set of sonames than the version provided by Void. We need to patch where the library sonames are hardcoded to allow julia to properly call into libraries provided by mbedtls. Closes void-linux#29964 and void-linux#30061 See <JuliaLang/julia#40198> for the upstream bug.
Also change to using vendored llvm to reduce maintenance burden from julia depending on versions of llvm which are quickly obsoleted; this should also fix julia's build being broken on i686. When julia 1.6.0 vendors in mbedtls, it uses v2.26.0 which provides a different set of sonames than the version provided by Void. We need to patch where the library sonames are hardcoded to allow julia to properly call into libraries provided by mbedtls. [Ed.: internal references to unversioned shlibs in this patch appear to refer to symlnks that the julia package creates in /usr/lib/julia rather than symlinks in /usr/lib that would require -devel dependencies.] Upstream issue: JuliaLang/julia#40198 Closes: void-linux#30703 [via git-merge-pr] Closes: void-linux#30490 Closes: void-linux#30061 Closes: void-linux#29964
Also change to using vendored llvm to reduce maintenance burden from julia depending on versions of llvm which are quickly obsoleted; this should also fix julia's build being broken on i686. When julia 1.6.0 vendors in mbedtls, it uses v2.26.0 which provides a different set of sonames than the version provided by Void. We need to patch where the library sonames are hardcoded to allow julia to properly call into libraries provided by mbedtls. [Ed.: internal references to unversioned shlibs in this patch appear to refer to symlnks that the julia package creates in /usr/lib/julia rather than symlinks in /usr/lib that would require -devel dependencies.] Upstream issue: JuliaLang/julia#40198 Closes: void-linux#30703 [via git-merge-pr] Closes: void-linux#30490 Closes: void-linux#30061 Closes: void-linux#29964
When julia 1.6.0 vendors in mbedtls, it uses v2.26.0 which provides a
different set of sonames than the version provided by Void. We need to
patch where the library sonames are hardcoded to allow julia to properly
call into libraries provided by mbedtls.
Closes #29964
See JuliaLang/julia#40198 for the upstream
bug.
This patch is directly copied from Arch Linux.
General
Have the results of the proposed changes been tested?