diff options
author | mharo <mharo@FreeBSD.org> | 2000-04-01 11:39:48 +0800 |
---|---|---|
committer | mharo <mharo@FreeBSD.org> | 2000-04-01 11:39:48 +0800 |
commit | caacc07b4106af4268189b75b1e8588cbe1f9235 (patch) | |
tree | 99a355928ae8e575e2297e7b22b04632fd098c01 /mail/popa3d/pkg-install | |
parent | ff3c4cfeb1d160858ac56e1a7303bc9bed13f818 (diff) | |
download | freebsd-ports-gnome-caacc07b4106af4268189b75b1e8588cbe1f9235.tar.gz freebsd-ports-gnome-caacc07b4106af4268189b75b1e8588cbe1f9235.tar.zst freebsd-ports-gnome-caacc07b4106af4268189b75b1e8588cbe1f9235.zip |
various port fixes
PR: 17180
Submitted by: maintainer
Diffstat (limited to 'mail/popa3d/pkg-install')
-rw-r--r-- | mail/popa3d/pkg-install | 51 |
1 files changed, 21 insertions, 30 deletions
diff --git a/mail/popa3d/pkg-install b/mail/popa3d/pkg-install index 7f90da837520..4f0e5c9c3ca2 100644 --- a/mail/popa3d/pkg-install +++ b/mail/popa3d/pkg-install @@ -1,39 +1,30 @@ -#!/bin/sh +# $FreeBSD$ +# -USER=popa3d -UID=89 -GID=89 -GROUP=popa3d -GECOS="popa3d" -HOME=/nonexistent -SHELL=/sbin/nologin +if [ "$2" != "PRE-INSTALL" ]; then + exit 0 +fi -case $2 in - PRE-INSTALL) - which -s pw || { - cat << EOF +PATH=/bin:/usr/bin -I see that it is missing the "pw" utility. I need this utility. -Please get it and install it, and try again. +use_vipw () { -EOF - exit 1 - } - pw groupshow $GROUP > /dev/null 2>&1 || { - pw groupadd $GROUP -g $GID; - } + cat << EOF + +You need an account "pop" to install this package. +Please add it by hand (try "man vipw") and try again. - pw usershow $USER > /dev/null 2>&1 || { - pw useradd $USER -g $GROUP -u $UID -h - -d $HOME -s $SHELL -c "$GECOS"; - } +An example passwd entry is: +pop:*:68:6::0:0:Post Office Owner:/nonexistent:/nonexistent - ;; - POST-INSTALL) +EOF - ;; - *) - echo "usage: $0 <pkg-name> {PRE-INSTALL|POST-INSTALL}" - exit 64 -esac +} + +if ! id -u "pop" > /dev/null 2>&1; then + use_vipw + exit 1 +fi exit 0 + |