[Pkg-rust-maintainers] Bug#1033014: debcargo: debian/debcargo.toml should permit including extra features for dh_auto_test

Daniel Kahn Gillmor dkg at fifthhorseman.net
Wed Mar 15 18:19:07 GMT 2023


Package: debcargo
Version: 2.6.0-2+b1
Control: affects -1 + src:rust-sequoia-net dh-cargo

debcargo's dh_auto_test fails by default for rust-sequoia-net version
0.26.0 unless i override it in debian/rules.  I think i ought to be able
to specify the particular additional thing i need in
debian/debcargo.toml and not have to port any sort of automated
difference from debcargo-generated debian/rules.

rust-sequoia-net 0.26.0 is in debian experimental at the moment.  It is
a library crate.  debcargo and dh-cargo together make it so that
dh_auto_test runs "cargo build" during build-time testing.

rust-sequoia-net depends on rust-sequoia-openpgp, and
rust-sequoia-openpgp requires that one of its "crypto-*" features be
enabled in order to work.

Currently, this works because i've made it use the following debian/rules:

```
#!/usr/bin/make -f
%:
	dh $@ --buildsystem cargo

# see https://gitlab.com/sequoia-pgp/sequoia/-/issues/990
override_dh_auto_test:
	dh_auto_test -- --features sequoia-openpgp/crypto-nettle
```

I see a couple different ways that this could be fixed:

 - instead of doing "cargo build" during dh_auto_test for library
   crates, it could do "cargo test", without -Zavoid-dev-deps -- i don't
   fully understand how much this would risk breaking other packages
   that use the same framework, though.

 - alternately, maybe i could declaratively specify in debcargo
   any additional features to append to `dh_auto_test`.

This might belong to dh-cargo, and not debcargo -- or maybe it's
something that needs to be addressed in both places.

          --dkg
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 227 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/pkg-rust-maintainers/attachments/20230315/f62ccf33/attachment.sig>


More information about the Pkg-rust-maintainers mailing list