[Pkg-rust-maintainers] Packaging advice/help wanted for anki, which has just started using some Rust
Julian Gilbey
jdg at debian.org
Tue Jan 21 10:00:29 GMT 2020
Dear all,
I maintain the Python-based package "anki", which has been almost no
problem up to now. But upstream have just started incorporating some
Rust code into it, and I've never used Rust myself. The build
mechanism they have written involves downloading and compiling Rust
modules (I think that's what it's doing) using rustup. Here's a piece
of the Makefile as an example:
# nightly currently required for ignoring files in rustfmt.toml
RUST_TOOLCHAIN := $(shell cat rust-toolchain)
.build/tools: requirements.txt rust-toolchain
pip install -r requirements.txt
rustup toolchain install $(RUST_TOOLCHAIN)
rustup component add rustfmt-preview --toolchain $(RUST_TOOLCHAIN)
rustup component add clippy-preview --toolchain $(RUST_TOOLCHAIN)
@touch $@
.build/check: build
cargo fmt -- --check
cargo clippy -- -D warnings
@touch $@
(This is a little weird, as there's no rule to make rust-toolchain.
Perhaps an error in the Makefile?)
So any advice on how to handle this? There is no "rustup" package in
Debian (presumably for a good reason), but I have found the list of
available rustup components here:
https://rust-lang.github.io/rustup-components-history/
Is there any way to do this process within the existing Debian Rust
infrastructure?
Also, is there a Debian Rust Policy? I haven't been able to find one
on a quick scan.
Many thanks,
Julian
More information about the Pkg-rust-maintainers
mailing list