]> git.donarmstrong.com Git - debhelper.git/blob - dh_installpam
r189: Initial revision
[debhelper.git] / dh_installpam
1 #!/usr/bin/perl -w
2 #
3 # Integration with debian pam system:
4 #
5 # If debian/pam file exists, save it to $TMP/etc/pam.d/$PACKAGE
6
7 BEGIN { push @INC, "debian", "/usr/lib/debhelper" }
8 use Dh_Lib;
9 init();
10
11 foreach $PACKAGE (@{$dh{DOPACKAGES}}) {
12         $TMP=tmpdir($PACKAGE);
13         $pam=pkgfile($PACKAGE,"pam");
14         
15         if ($pam ne '') {
16                 if (! -d "$TMP/etc/pam.d") {
17                         doit("install","-d","$TMP/etc/pam.d");
18                 }
19                 doit("install","-p","-m644",$pam,"$TMP/etc/pam.d/$PACKAGE");
20         }
21 }