Repository navigation
Disable generating exports file for System.IO.Compression.Native on mobile - #46222
Merged
Merged
Conversation
…obile dotnet#45995 added this and it relies on this code in configuretools.cmake to detect which linker is used: https://github.com/dotnet/runtime/blob/4bc323242d43dda85d490c0630c4637ffc092469/eng/native/configuretools.cmake#L66-L86 However passing `-Wl,--version` to the compiler doesn't seem to work when using the clang provided by the Android NDK, it still uses the system linker in /usr/bin/ld. On OSX that one doesn't support the `--version` option so we don't detect LD_GNU which we'd need for providing the correct `-Wl,--version-script` compiler option. It looks like this only passed on the PR because we build Android on Linux there and the system linker _is_ GNU there so the check was successful. Disable the generation of the exports file on mobile platforms since we don't use it there anyway.
Member
|
This is a bit unfortunate. The idea of exports file is to reduce the default exports from 3rd party code (Brotli primarily) to the minimum we need and perhaps let the linker trim away something unused. Not doing this would not be worse than before, so it is ok too. |
VSadov
approved these changes
Dec 18, 2020
Member
Author
|
Yeah I'm sure we can find a way to make it work, just wanted to unbreak the macOS build first :) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#45995 added this and it relies on this code in configuretools.cmake to detect which linker is used:
runtime/eng/native/configuretools.cmake
Lines 66 to 86 in 4bc3232
However passing
-Wl,--versionto the compiler doesn't seem to work when using the clang provided by the Android NDK, it still uses the system linker in/usr/bin/ld.On OSX that one doesn't support the
--versionoption so we don't detect LD_GNU which we'd need for providing the correct-Wl,--version-scriptcompiler option.It looks like this only passed on the PR because we build Android on Linux there and the system linker is GNU there so the check was successful.
Disable the generation of the exports file on mobile platforms since we don't use it there anyway.