#977491 debcargo: no clear way to indicate that a "feature" is actually a build-dep for a binary crate

Package:
debcargo
Source:
rust-debcargo
Description:
Create a Debian package from a Cargo crate
Submitter:
Daniel Kahn Gillmor
Date:
2020-12-15 17:03:04 UTC
Severity:
normal
#977491#5
Date:
2020-12-15 16:56:59 UTC
From:
To:
I'm looking at the sha1collisiondetection crate.  this crate produces a
library and a binary ("sha1cdsum").

The binary needs to build against the structopt crate, but the library
doesn't need it.

Upstream represents this as the library having a structopt "feature",
which the binary requires.

But debcargo maps this into wanting to produce a "structopt" feature for
the library.  We don't *want* that additional feature package.  Or,
under the new rust packaging regime, we don't want that additional
dependency for the bundled all-Provides librust-*-dev package.

So i'd like for debcargo to have a way to indicate that a particular
feature should be ignored when packaging the library (but not ignored as
a build-depends).