summaryrefslogtreecommitdiff
path: root/dh_install
diff options
context:
space:
mode:
authorJoey Hess <joey@gnu.kitenet.net>2009-06-30 13:04:11 -0400
committerJoey Hess <joey@gnu.kitenet.net>2009-06-30 13:04:11 -0400
commit220fc31652cf112b333c195cde759fe5f04d182f (patch)
treeece7075eb177a57aa3d9a0313048f3359da21691 /dh_install
parent9a867d7d344bc3c59a3326123f7323655c311d6c (diff)
parent9089acf8dcc683db171f1f5be12c9424cf89aa6f (diff)
Merge branch 'master' into buildsystems
Conflicts: debian/changelog
Diffstat (limited to 'dh_install')
-rwxr-xr-xdh_install10
1 files changed, 3 insertions, 7 deletions
diff --git a/dh_install b/dh_install
index 86a868b..ccec471 100755
--- a/dh_install
+++ b/dh_install
@@ -117,7 +117,7 @@ init(options => {
my @installed;
my $srcdir = '.';
-$srcdir = $dh{SOURCEDIR}."/" if defined $dh{SOURCEDIR};
+$srcdir = $dh{SOURCEDIR} if defined $dh{SOURCEDIR};
foreach my $package (@{$dh{DOPACKAGES}}) {
my $tmp=tmpdir($package);
@@ -151,7 +151,7 @@ foreach my $package (@{$dh{DOPACKAGES}}) {
my @found = glob "$srcdir/$glob";
if (! compat(6)) {
# Fall back to looking in debian/tmp.
- if (! @found || ! -e $found[0]) {
+ if (! @found || ! (-e $found[0] || -l $found[0])) {
@found = glob "debian/tmp/$glob";
}
}
@@ -170,11 +170,7 @@ foreach my $package (@{$dh{DOPACKAGES}}) {
if (! defined $dest) {
# Guess at destination directory.
$dest=$src;
- my $strip=$srcdir;
- if ($strip eq '.') {
- $strip = "debian/tmp";
- }
- $dest=~s/^(.*\/)?\Q$strip\E//;
+ $dest=~s/^(.*\/)?(\Q$srcdir\E|debian\/tmp)\///;
$dest=dirname($dest);
$tmpdest=1;
}