+debhelper (6.0.1) UNRELEASED; urgency=low
+
+ * dh_installdocs/examples: Don't unnecessarily use the exclude code path.
+ * Avoid infiinite recursion when told to install a directory ending with
+ "/." (slashdot effect?). Indeed, arbitrarily complex paths can be used
+ now, although there's really no point in using them. Closes: #253234
+
+ -- Joey Hess <joeyh@debian.org> Fri, 11 Jan 2008 13:38:10 -0500
+
debhelper (6.0.0) unstable; urgency=low
* dh_gencontrol: Stop passing -isp, it's the default now. Closes: #458114
use strict;
use File::Find;
use Debian::Debhelper::Dh_Lib;
+use Cwd q{abs_path};
=head1 SYNOPSIS
}
if (-d $src && $exclude) {
- my ($dir_basename) = basename($src);
+ my ($dir_basename) = basename(abs_path($src));
# Pity there's no cp --exclude ..
my $pwd=`pwd`;
chomp $pwd;
use strict;
use Debian::Debhelper::Dh_Lib;
+use Cwd q{abs_path};
=head1 SYNOPSIS
}
if (@docs) {
- my $exclude = '\\( -type f -or -type l \\)';
+ my $exclude = '';
if ($dh{EXCLUDE_FIND}) {
$exclude .= ' -and ! \( '.$dh{EXCLUDE_FIND}.' \)';
}
next if excludefile($doc);
next if -e $doc && ! -s $doc && ! compat(4); # ignore empty files
if (-d $doc && length $exclude) {
- my ($dir_basename) = basename($doc);
- my $pwd=`pwd`;
- chomp $pwd;
- complex_doit("cd '$doc/..' && find '$dir_basename' $exclude -exec cp --parents -dp {} $pwd/$tmp/usr/share/doc/$package \\;");
+ my ($dir_basename) = basename(abs_path($doc));
+ my $pwd=`pwd`;
+ chomp $pwd;
+ $exclude='\\( -type f -or -type l \\)'.$exclude;
+ complex_doit("cd '$doc/..' && find '$dir_basename' $exclude -exec cp --parents -dp {} $pwd/$tmp/usr/share/doc/$package \\;");
}
else {
doit("cp", "-a", $doc, "$tmp/usr/share/doc/$package");
use strict;
use Debian::Debhelper::Dh_Lib;
+use Cwd q{abs_path};
=head1 SYNOPSIS
doit("install","-d","$tmp/usr/share/doc/$package/examples");
}
- my $exclude = '-type f';
+ my $exclude = '';
if ($dh{EXCLUDE_FIND}) {
$exclude .= ' -and ! \( '.$dh{EXCLUDE_FIND}.' \)';
}
foreach my $example (@examples) {
next if excludefile($example);
if (-d $example && $exclude) {
- my ($dir_basename) = basename($example);
+ my ($dir_basename) = basename(abs_path($example));
my $pwd=`pwd`;
chomp $pwd;
+ $exclude = '-type f'.$exclude;
complex_doit("cd '$example/..' && find '$dir_basename' $exclude -exec cp --parents -dp {} $pwd/$tmp/usr/share/doc/$package/examples \\;");
}
else {