fix: support arm64 build for Linux #1225
Merged
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.
Users were running into issues with glibc mismatches on arm64 linux. In the past, we did not provide a musl build for arm64 Linux because we had trouble getting the openssl dependency to build correctly. Though today I just tried the same trick in
Cargo.tomlthat we were doing forx86_64-unknown-linux-musl(usingopenssl-syswithfeatures = ["vendored"]), so I'm not sure what problem we had in the past the builds "just worked" today!Though one tweak that did have to be made is that the integration tests for Seccomp/Landlock empirically require longer timeouts on arm64 linux, or at least on the
ubuntu-24.04-armGitHub Runner. As such, we change the timeouts for arm64 incodex-rs/linux-sandbox/tests/landlock.rs.Though in solving this problem, I decided I needed a turnkey solution for testing the Linux build(s) from my Mac laptop, so this PR introduces
.devcontainer/Dockerfileand.devcontainer/devcontainer.jsonto facilitate this. Detailed instructions are in.devcontainer/README.md.We will update
dotslash-config.jsonand other release-related scripts in a follow-up PR.