Support packages with ruzt-* prefix to help with debcargo testing

This commit is contained in:
Ximin Luo 2021-11-07 12:57:00 +00:00
parent 4f3ae1fecd
commit 5cc7f7b861
2 changed files with 8 additions and 2 deletions

View File

@ -85,7 +85,7 @@ sub pre_building_step {
my $crate = $source->{'X-Cargo-Crate'}; my $crate = $source->{'X-Cargo-Crate'};
if (!$crate) { if (!$crate) {
$crate = $source->{Source}; $crate = $source->{Source};
$crate =~ s/^rust-//; $crate =~ s/^ru[sz]t-//;
$crate =~ s/-[0-9]+(\.[0-9]+)*$//; $crate =~ s/-[0-9]+(\.[0-9]+)*$//;
} }
$this->{crate} = $crate; $this->{crate} = $crate;
@ -98,7 +98,7 @@ sub pre_building_step {
$this->{binpkg} = 0; $this->{binpkg} = 0;
$this->{featurepkg} = []; $this->{featurepkg} = [];
foreach my $package (@packages) { foreach my $package (@packages) {
if ($package->{Package} =~ /^librust-.*-dev$/) { if ($package->{Package} =~ /^libru[sz]t-.*-dev$/) {
if ($package->{Package} =~ /\+/) { if ($package->{Package} =~ /\+/) {
push(@{$this->{featurepkg}}, $package->{Package}); push(@{$this->{featurepkg}}, $package->{Package});
next; next;

6
debian/changelog vendored
View File

@ -1,3 +1,9 @@
dh-cargo (28) UNRELEASED; urgency=medium
* Support packages with ruzt-* prefix to help with debcargo testing.
-- Ximin Luo <infinity0@debian.org> Sun, 07 Nov 2021 12:56:11 +0000
dh-cargo (27) unstable; urgency=medium dh-cargo (27) unstable; urgency=medium
* Minor tweak to help with debcargo testing; no behavioural changes. * Minor tweak to help with debcargo testing; no behavioural changes.