Fix aarch64 cross-compile: switch reqwest to rustls-tls - #11
Merged
Conversation
The default reqwest TLS backend (native-tls) pulls in openssl-sys, which requires a system OpenSSL that isn't present when the release workflow cross-compiles to aarch64-unknown-linux-gnu, failing the build. Switch to rustls-tls (pure Rust) so no system library is needed on any target. Defaults charset/http2/system-proxy are re-enabled explicitly since default-features is now off.
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Problem
The release workflow cross-compiles to
aarch64-unknown-linux-gnuviacross, and the build fails:reqwest's defaultdefault-tlsfeature usesnative-tls→openssl-sys, which needs a system OpenSSL that isn't present in the cross build environment for the target arch.Fix
Switch reqwest to
rustls-tls(pure-Rust TLS, no system dependency).openssl-sysis now entirely absent from the dependency tree, so every target — including aarch64 — builds without a system OpenSSL.Because this requires
default-features = false, the other reqwest defaults (charset,http2,system-proxy) are re-listed explicitly so behavior is otherwise unchanged.Verification
cargo tree -i openssl-sys→ no match (removed)cargo tree -i rustls→ present via hyper-rustls/reqwest