pass DEB_MAINT_PARAMS to hook scripts

hook scripts like to know the invoked maintainer script options.

svn path=/dists/trunk/linux-2.6/; revision=15014
This commit is contained in:
Maximilian Attems 2010-01-26 17:24:06 +00:00
parent 60e4953382
commit 2c83717624
5 changed files with 29 additions and 0 deletions

1
debian/changelog vendored
View File

@ -68,6 +68,7 @@ linux-2.6 (2.6.32-6) UNRELEASED; urgency=low
(closes: #565494), ITCO_VENDOR_SUPPORT (closes: #525232), PCIEASPM
(closes: #545417).
* Enable easier debugging of Power Managment code. (closes: #478315)
* Pass `DEB_MAINT_PARAMS' to hook scripts. (closes: #563161)
-- Ben Hutchings <ben@decadent.org.uk> Sun, 10 Jan 2010 17:38:50 +0000

View File

@ -853,6 +853,13 @@ sub run_hook {
}
}
my $options;
for (@ARGV) {
s,','\\'',g;
$options .= " '$_'";
}
$ENV{'DEB_MAINT_PARAMS'}="$options";
## Run user hook script here, if any
if ($postinst_hook) {
&run_hook("postinst", $postinst_hook);

View File

@ -256,6 +256,13 @@ sub run_hook {
}
}
my $options;
for (@ARGV) {
s,','\\'',g;
$options .= " '$_'";
}
$ENV{'DEB_MAINT_PARAMS'}="$options";
## Run user hook script here, if any
if ($postrm_hook) {
&run_hook("postrm", $postrm_hook);

View File

@ -184,6 +184,13 @@ sub run_hook {
}
my $options;
for (@ARGV) {
s,','\\'',g;
$options .= " '$_'";
}
$ENV{'DEB_MAINT_PARAMS'}="$options";
## Run user hook script here, if any
if (-x "$preinst_hook") {
&run_hook("preinst", $preinst_hook);

View File

@ -264,6 +264,13 @@ sub run_hook {
}
my $options;
for (@ARGV) {
s,','\\'',g;
$options .= " '$_'";
}
$ENV{'DEB_MAINT_PARAMS'}="$options";
## Run user hook script here, if any
if (-x "$prerm_hook") {
&run_hook("prerm", $prerm_hook);