[debhelper-devel] [debhelper] 03/06: dh_builddeb: Pass --root-owner-group to dpkg-deb under R³ in null-owner mode
Niels Thykier
nthykier at moszumanska.debian.org
Wed Oct 18 21:02:25 UTC 2017
This is an automated email from the git hooks/post-receive script.
nthykier pushed a commit to branch support-rrr
in repository debhelper.
commit d6db2e8f2ea91b0d87f233a175f8cc9ab046d09b
Author: Niels Thykier <niels at thykier.net>
Date: Sun Oct 15 14:24:11 2017 +0000
dh_builddeb: Pass --root-owner-group to dpkg-deb under R³ in null-owner mode
Signed-off-by: Niels Thykier <niels at thykier.net>
---
debian/changelog | 2 ++
dh_builddeb | 10 ++++++++--
2 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index dc1510d..7d610e3 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -17,6 +17,8 @@ debhelper (10.9.3) UNRELEASED; urgency=medium
* dh_testroot: Update check for root to support R³.
* makefile.pm: Call "make install" with DPKG_GAIN_ROOT_CMD when
R³ contains the "debhelper/upstream-make-install" keyword.
+ * dh_builddeb: Pass --root-owner-group to dpkg-deb in packages
+ with R³ (except for "binary-targets").
-- Niels Thykier <niels at thykier.net> Sat, 14 Oct 2017 11:18:19 +0000
diff --git a/dh_builddeb b/dh_builddeb
index a412789..1dd90b1 100755
--- a/dh_builddeb
+++ b/dh_builddeb
@@ -25,6 +25,9 @@ and L<dh_gencontrol(1)> have prepared them.
It supports building multiple binary packages in parallel, when enabled by
DEB_BUILD_OPTIONS.
+Under the B<rootless-build-nulling-ownership> sequence, B<dh_builddeb>
+will pass B<--root-owner-group> to L<dpkg-deb(1)>.
+
=head1 OPTIONS
=over 4
@@ -99,6 +102,8 @@ sub build_and_rename_deb {
}
my @items;
+my @dpkg_options;
+push(@dpkg_options, '--root-owner-group') if not should_use_root();
for my $package (@{$dh{DOPACKAGES}}) {
push(@items, [$package, 0]);
@@ -123,7 +128,7 @@ on_items_in_parallel(\@items, sub {
if ($dbgsym) {
my $dbgsym_tmpdir = "debian/.debhelper/${package}/dbgsym-root";
- doit("dpkg-deb", @{$dh{U_PARAMS}},
+ doit("dpkg-deb", @dpkg_options, @{$dh{U_PARAMS}},
"--build", $dbgsym_tmpdir, $dh{DESTDIR});
next;
}
@@ -139,11 +144,12 @@ on_items_in_parallel(\@items, sub {
}
}
if (! is_udeb($package)) {
- doit("dpkg-deb", @{$dh{U_PARAMS}}, "--build", $tmp, $dh{DESTDIR}.$dh{FILENAME});
+ doit("dpkg-deb", @dpkg_options, @{$dh{U_PARAMS}}, "--build", $tmp, $dh{DESTDIR}.$dh{FILENAME});
}
else {
my $filename=$dh{FILENAME};
my @cmd = qw(dpkg-deb -z6 -Zxz -Sextreme);
+ push(@cmd, @dpkg_options);
push(@cmd, @{$dh{U_PARAMS}}) if $dh{U_PARAMS};
push(@cmd, '--build', $tmp);
if (! $filename) {
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debhelper/debhelper.git
More information about the debhelper-devel
mailing list