summaryrefslogtreecommitdiff
path: root/dh_installdeb
diff options
context:
space:
mode:
authorjoey <joey>2005-03-27 16:57:47 +0000
committerjoey <joey>2005-03-27 16:57:47 +0000
commit269a2b129ec031f94e54dca7f526b2127aaf599f (patch)
tree7d60401d19b18c5dcf3965b82f1347f5bb90548f /dh_installdeb
parent79fa169d452a5e548482d3aa33f2a81a99228f93 (diff)
r1743: releasing version 4.2.32
Diffstat (limited to 'dh_installdeb')
-rwxr-xr-xdh_installdeb32
1 files changed, 3 insertions, 29 deletions
diff --git a/dh_installdeb b/dh_installdeb
index 9832d102..519afb0c 100755
--- a/dh_installdeb
+++ b/dh_installdeb
@@ -46,7 +46,6 @@ init();
foreach my $package (@{$dh{DOPACKAGES}}) {
my $tmp=tmpdir($package);
- my $ext=pkgext($package);
if (! -d "$tmp/DEBIAN") {
doit("install","-o",0,"-g",0,"-d","$tmp/DEBIAN");
@@ -62,34 +61,9 @@ foreach my $package (@{$dh{DOPACKAGES}}) {
next;
}
- # Install debian install scripts.
- # If any .debhelper files exist, add them into the scripts.
- foreach my $file (qw{postinst preinst prerm postrm}) {
- my $f=pkgfile($package,$file);
- if ($f) {
- if (-f "debian/$ext$file.debhelper") {
- # Add this into the script, where it has
- # #DEBHELPER#
- complex_doit("perl -pe 's~#DEBHELPER#~qx{cat debian/$ext$file.debhelper}~eg' < $f > $tmp/DEBIAN/$file");
- }
- else {
- # Just get rid of any #DEBHELPER# in the
- # script.
- complex_doit("sed s/#DEBHELPER#// < $f > $tmp/DEBIAN/$file");
- }
- doit("chown","0:0","$tmp/DEBIAN/$file");
- doit("chmod",755,"$tmp/DEBIAN/$file");
- }
- else {
- # Auto-generate script header and add .debhelper
- # content to it.
- if (-f "debian/$ext$file.debhelper") {
- complex_doit("printf '#!/bin/sh\nset -e\n' > $tmp/DEBIAN/$file");
- complex_doit("cat debian/$ext$file.debhelper >> $tmp/DEBIAN/$file");
- doit("chown","0:0","$tmp/DEBIAN/$file");
- doit("chmod",755,"$tmp/DEBIAN/$file");
- }
- }
+ # Install debian scripts.
+ foreach my $script (qw{postinst preinst prerm postrm}) {
+ debhelper_script_subst($package, $script);
}
# Install non-executable files