summaryrefslogtreecommitdiff
path: root/dh_installinfo
diff options
context:
space:
mode:
authorjoey <joey>2001-02-09 00:57:53 +0000
committerjoey <joey>2001-02-09 00:57:53 +0000
commit053f6f8b4e7431d32511aef209188a084e8c7e79 (patch)
tree209a51c8c8fdbcce25c834198f1b3ef705dcb5b0 /dh_installinfo
parentae0346306694bb2c52193f6352755c223e6e8935 (diff)
r420: big monsta changes
Diffstat (limited to 'dh_installinfo')
-rwxr-xr-xdh_installinfo29
1 files changed, 15 insertions, 14 deletions
diff --git a/dh_installinfo b/dh_installinfo
index 146aede9..702f4ee8 100755
--- a/dh_installinfo
+++ b/dh_installinfo
@@ -3,30 +3,31 @@
# Reads debian/info, installs all files listed there into /usr/share/info
# and puts appropriate commands into the postinst.
+use strict;
use Debian::Debhelper::Dh_Lib;
init();
-foreach $PACKAGE (@{$dh{DOPACKAGES}}) {
- $TMP=tmpdir($PACKAGE);
- $file=pkgfile($PACKAGE,"info");
+foreach my $package (@{$dh{DOPACKAGES}}) {
+ my $tmp=tmpdir($package);
+ my $file=pkgfile($package,"info");
- undef @info;
+ my @info;
if ($file) {
@info=filearray($file, ".");
}
- if (($PACKAGE eq $dh{FIRSTPACKAGE} || $dh{PARAMS_ALL}) && @ARGV) {
+ if (($package eq $dh{FIRSTPACKAGE} || $dh{PARAMS_ALL}) && @ARGV) {
push @info, @ARGV;
}
if (@info) {
- if ( ! -d "$TMP/usr/share/info") {
- doit("install","-d","$TMP/usr/share/info");
+ if ( ! -d "$tmp/usr/share/info") {
+ doit("install","-d","$tmp/usr/share/info");
}
- doit("cp",@info,"$TMP/usr/share/info");
- doit("chmod","-R", "go=rX","$TMP/usr/share/info/");
- doit("chmod","-R", "u+rw","$TMP/usr/share/info/");
+ doit("cp",@info,"$tmp/usr/share/info");
+ doit("chmod","-R", "go=rX","$tmp/usr/share/info/");
+ doit("chmod","-R", "u+rw","$tmp/usr/share/info/");
}
foreach $file (@info) {
@@ -44,18 +45,18 @@ foreach $PACKAGE (@{$dh{DOPACKAGES}}) {
}
close IN;
- my $fn="/usr/share/info/".Debian::Debhelper::Dh_Lib::basename($file);
+ my $fn="/usr/share/info/".basename($file);
if ($section ne '') {
$section=~s:/:\\/:g; # allow / in section.
- autoscript($PACKAGE,"postinst","postinst-info",
+ autoscript($package,"postinst","postinst-info",
"s/#SECTION#/$section/g;s:#FILE#:$fn:");
}
else {
- autoscript($PACKAGE,"postinst","postinst-info-nosection",
+ autoscript($package,"postinst","postinst-info-nosection",
"s:#FILE#:$fn:");
}
- autoscript($PACKAGE,"prerm","prerm-info", "s:#FILE#:$fn:");
+ autoscript($package,"prerm","prerm-info", "s:#FILE#:$fn:");
}
}
}