You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In response to #230, you kindly added ARM64 binaries for aarch64-apple-darwin, aarch64-pc-windows-msvc, and aarch64-unknown-linux-gnu. However, aarch64-unknown-linux-musl was not included in that expansion.
I'm trying to enable cargo-auditable from within cargo-dist in my project, but I have customized the build setup a bit to build musl targets in a dedicated Rust Alpine container. That causes a failure in the dist-generated workflow that tries to install cargo-auditable with the install script. The installer script's select_archive_for_arch() has no case for aarch64-unknown-linux-musl-dynamic (or -static), so it hard-errors on that platform:
there isn't a download for your platform aarch64-unknown-linux-musl-dynamic
The x86_64-unknown-linux-musl target works fine since a prebuilt binary exists for that triple, so I assume the musl target for aarch64 was just not used by anyone up until now.
The fix should be a one-line addition to the targets list in Cargo.toml, the same change PR #231 made for the other ARM64 triples. I'm happy to submit a PR if that's helpful.
The fix should be a one-line addition to the targets list in Cargo.toml, the same change PR #231 made for the other ARM64 triples. I'm happy to submit a PR if that's helpful.
I'm not sure it's that simple. We're already enabling all available dist targets:
$ dist init
let's setup your dist config...
? Would you like to opt in to the new configuration format?
Future versions of dist will feature major changes to the
✔ Would you like to opt in to the new configuration format?
Future versions of dist will feature major changes to the
configuration format, including a new dist-specific configuration file. · no
? what platforms do you want to build for?
(select with arrow keys and space, submit with enter) ›
[x] Apple Silicon macOS (aarch64-apple-darwin)
[x] ARM64 Linux (aarch64-unknown-linux-gnu)
[x] ARM64 Windows (aarch64-pc-windows-msvc)
[x] Intel macOS (x86_64-apple-darwin)
[x] x64 Linux (x86_64-unknown-linux-gnu)
[x] x64 MUSL Linux (x86_64-unknown-linux-musl)
[x] x64 Windows (x86_64-pc-windows-msvc)
There is no aarch64-unknown-linux-musl option; so I'm not sure if this will actually work or not.
I'm not really willing to maintain a custom, complex cargo-dist configuration. Please contribute aarch64-unknown-linux-musl support to cargo-dist itself so that it exposes it as a supported option, and then I'll gladly enable it.
Or, since you're using a custom container anyway, you might as well install cargo auditable into it yourself. I'm not sure if cargo dist will try to download a release anyway, but it should be a trivial upstream patch to make it not do that.
Ah, yes you're right. Installing cargo auditable unfortunately doesn't help, since cargo-dist unconditionally runs the cargo-auditable install script which fails when the target is unsupported. I'll see about getting that target supported in cargo-dist, and come back here when it's done. Thanks for the quick response!
You can use cargo install cargo-auditable instead of using the precompiled binaries.
I wasn't able to get that to work, because cargo-dist will still try to explicitly install cargo-auditable with its install script, which then fails because there are no musl aarch64 binaries.
I've submitted a PR here to enable that build target in cargo-dist which I think will solve the problem.
I wasn't able to get that to work, because cargo-dist will still try to explicitly install cargo-auditable with its install script, which then fails because there are no musl aarch64 binaries.
This was a suggestion to do during your container build in the place of downloading a precompiled binary. No cargo-dist would be involved when doing that.
Given that it turns out cargo-dist is able to build for arm64 musl, #250 is probably a nicer solution though.
Activity
Shnatsel commentedon Mar 17, 2026
I'm not sure it's that simple. We're already enabling all available dist targets:
There is no aarch64-unknown-linux-musl option; so I'm not sure if this will actually work or not.
I'm not really willing to maintain a custom, complex cargo-dist configuration. Please contribute aarch64-unknown-linux-musl support to cargo-dist itself so that it exposes it as a supported option, and then I'll gladly enable it.
Shnatsel commentedon Mar 17, 2026
Or, since you're using a custom container anyway, you might as well install
cargo auditableinto it yourself. I'm not sure ifcargo distwill try to download a release anyway, but it should be a trivial upstream patch to make it not do that.anelson commentedon Mar 18, 2026
Ah, yes you're right. Installing
cargo auditableunfortunately doesn't help, sincecargo-distunconditionally runs thecargo-auditableinstall script which fails when the target is unsupported. I'll see about getting that target supported incargo-dist, and come back here when it's done. Thanks for the quick response!Add `aarch64-unknown-linux-musl` to dist targets
bjorn3 commentedon Mar 18, 2026
You can use
cargo install cargo-auditableinstead of using the precompiled binaries.anelson commentedon Mar 18, 2026
I wasn't able to get that to work, because
cargo-distwill still try to explicitly installcargo-auditablewith its install script, which then fails because there are no musl aarch64 binaries.I've submitted a PR here to enable that build target in cargo-dist which I think will solve the problem.
bjorn3 commentedon Mar 18, 2026
This was a suggestion to do during your container build in the place of downloading a precompiled binary. No cargo-dist would be involved when doing that.
Given that it turns out cargo-dist is able to build for arm64 musl, #250 is probably a nicer solution though.