summaryrefslogtreecommitdiff
path: root/scripts/Dpkg/Source
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/Dpkg/Source')
-rw-r--r--scripts/Dpkg/Source/Archive.pm5
1 files changed, 3 insertions, 2 deletions
diff --git a/scripts/Dpkg/Source/Archive.pm b/scripts/Dpkg/Source/Archive.pm
index bb2a40df4..ba377c045 100644
--- a/scripts/Dpkg/Source/Archive.pm
+++ b/scripts/Dpkg/Source/Archive.pm
@@ -26,6 +26,7 @@ use File::Basename qw(basename);
use File::Spec;
use Cwd;
+use Dpkg ();
use Dpkg::Gettext;
use Dpkg::ErrorHandling;
use Dpkg::IPC;
@@ -50,7 +51,7 @@ sub create {
my $mtime = $opts{source_date} // $ENV{SOURCE_DATE_EPOCH} // time;
# Call tar creation process
$spawn_opts{delete_env} = [ 'TAR_OPTIONS' ];
- $spawn_opts{exec} = [ 'tar', '-cf', '-', '--format=gnu', '--sort=name',
+ $spawn_opts{exec} = [ $Dpkg::PROGTAR, '-cf', '-', '--format=gnu', '--sort=name',
'--mtime', "\@$mtime", '--clamp-mtime', '--null',
'--numeric-owner', '--owner=0', '--group=0',
@{$opts{options}}, '-T', '-' ];
@@ -129,7 +130,7 @@ sub extract {
# Call tar extraction process
$spawn_opts{delete_env} = [ 'TAR_OPTIONS' ];
- $spawn_opts{exec} = [ 'tar', '-xf', '-', '--no-same-permissions',
+ $spawn_opts{exec} = [ $Dpkg::PROGTAR, '-xf', '-', '--no-same-permissions',
'--no-same-owner', @{$opts{options}} ];
spawn(%spawn_opts);
$self->close();