diff options
author | Niels Thykier <niels@thykier.net> | 2018-02-18 07:50:12 +0000 |
---|---|---|
committer | Niels Thykier <niels@thykier.net> | 2018-02-18 07:50:12 +0000 |
commit | e6b3ba49d0e1504966eaeb58dca280ea3c8310bc (patch) | |
tree | 4c9a09c73d43ef2d4b87c58f2baa272ee3581220 /dh_testroot | |
parent | 9986bc5c1ea30c8c4df51605b4f3916825aa263a (diff) | |
download | debhelper-e6b3ba49d0e1504966eaeb58dca280ea3c8310bc.tar.gz |
dh_testroot: root_requirements() no longer read d/control
Signed-off-by: Niels Thykier <niels@thykier.net>
Diffstat (limited to 'dh_testroot')
-rwxr-xr-x | dh_testroot | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/dh_testroot b/dh_testroot index 4fbd18fe..fca7cb1a 100755 --- a/dh_testroot +++ b/dh_testroot @@ -50,11 +50,9 @@ our $VERSION = DH_BUILTIN_VERSION; inhibit_log(); -my $requirements = 'legacy-root'; +my $requirements = Debian::Debhelper::Dh_Lib::root_requirements(); -if (-f 'debian/control') { - $requirements = Debian::Debhelper::Dh_Lib::root_requirements(); -} else { +if (! -f 'debian/control') { warning('dh_testroot must be called from the source root'); } @@ -67,7 +65,7 @@ if ($requirements eq 'legacy-root') { error("You must run this as root (or use fakeroot)."); } else { my $env = $ENV{DEB_GAIN_ROOT_CMD}; - error("Package needs targetted root but builder has not provided a gain-root command via \${DEB_GAIN_ROOT_CMD}") + error("Package needs targeted root but builder has not provided a gain-root command via \${DEB_GAIN_ROOT_CMD}") if not $env; } |