cargo-packager icon indicating copy to clipboard operation
cargo-packager copied to clipboard

Feature Request: Add `riscv64gc-unknown-linux-gnu` Target Support

Open Benji377 opened this issue 6 months ago • 0 comments

Description:

The cargo-packager CLI currently does not support the riscv64gc-unknown-linux-gnu target, even though it is officially supported by cargo.

When building with this target using cargo build, the process completes successfully:

cargo build  --release --target=riscv64gc-unknown-linux-gnu

Environment:

CARGO_HOME=/home/runner/.cargo
CARGO_INCREMENTAL=0
CARGO_TERM_COLOR=always
CACHE_ON_FAILURE=false
PKG_CONFIG_SYSROOT_DIR=/usr/riscv64-linux-gnu/

However, attempting to package the same binary with cargo packager results in an error:

cargo packager --target=riscv64gc-unknown-linux-gnu --formats=deb --release --verbose
ERROR cargo_packager::cli: Unexpected target triple: riscv64gc-unknown-linux-gnu
Error: Process completed with exit code 1.

Suggestion:

It would be great to add support for this target in cargo-packager, especially since the Tauri project has already added riscv64 support via tauri#12602.

This addition would make it possible to build and package Rust applications for the RISC-V ecosystem using the same toolchain and workflows as for other architectures.

Benji377 avatar Jun 11 '25 14:06 Benji377