aboutsummaryrefslogtreecommitdiffstats
path: root/mail/vpopmail-devel/pkg-install
diff options
context:
space:
mode:
Diffstat (limited to 'mail/vpopmail-devel/pkg-install')
-rw-r--r--mail/vpopmail-devel/pkg-install22
1 files changed, 22 insertions, 0 deletions
diff --git a/mail/vpopmail-devel/pkg-install b/mail/vpopmail-devel/pkg-install
index f3004e7de913..101602472771 100644
--- a/mail/vpopmail-devel/pkg-install
+++ b/mail/vpopmail-devel/pkg-install
@@ -8,10 +8,32 @@
%gids = ("vchkpw", 89);
%uids = ('vpopmail', 89);
+sub checkenv () {
+ my ($u, $g);
+
+ # Users
+ foreach $u (keys %users) {
+ $var = uc($u)."_UID";
+ if (defined($ENV{$var})) {
+ $uids{$u} = $ENV{$var};
+ }
+ }
+
+ # Groups
+ foreach $g (@groups) {
+ $var = uc($g)."_GID";
+ if (defined($ENV{$var})) {
+ $gids{$g} = $ENV{$var};
+ }
+ }
+}
+
if ($ENV{PACKAGE_BUILDING} || $ARGV[1] eq "PRE-INSTALL") {
$doguid=1; # Make sure we get the assigned guids.
}
+checkenv();
+
foreach $group (@groups) {
if (! getgrnam ($group)) {
do checkrpw; # May exit