summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorwiz <wiz@pkgsrc.org>2000-08-17 02:26:26 +0000
committerwiz <wiz@pkgsrc.org>2000-08-17 02:26:26 +0000
commit1b6dd0619e5d308d9038af1fbf458fedff4a29da (patch)
treea97eb9d7f99b2c40ea0fef10d31edb2bc03c3341
parent4bf506aa3573cb0c76a2d422869319993ccc73be (diff)
downloadpkgsrc-1b6dd0619e5d308d9038af1fbf458fedff4a29da.tar.gz
USE_PKGLIBTOOL -> USE_LIBTOOL.
While I'm here, convert it from addnerd to user.
-rw-r--r--sysutils/amanda-client/Makefile3
-rw-r--r--sysutils/amanda-client/pkg/PLIST3
-rw-r--r--sysutils/amanda-common/Makefile31
-rw-r--r--sysutils/amanda-common/Makefile.common4
-rw-r--r--sysutils/amanda-common/pkg/DEINSTALL27
-rw-r--r--sysutils/amanda-common/pkg/INSTALL45
-rw-r--r--sysutils/amanda-common/pkg/PLIST4
-rw-r--r--sysutils/amanda-server/pkg/PLIST3
8 files changed, 104 insertions, 16 deletions
diff --git a/sysutils/amanda-client/Makefile b/sysutils/amanda-client/Makefile
index dc1d4cbca66..23378217c57 100644
--- a/sysutils/amanda-client/Makefile
+++ b/sysutils/amanda-client/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.15 2000/07/20 15:26:19 tron Exp $
+# $NetBSD: Makefile,v 1.16 2000/08/17 02:26:26 wiz Exp $
# FreeBSD Id: Makefile,v 1.9 1997/03/08 05:00:11 gpalmer Exp
#
@@ -14,7 +14,6 @@ DEPENDS+= readline>=4.0:../../devel/readline
DEPENDS+= gtar-1.12:../../archivers/gtar
DEPENDS+= amanda-common-2.4.1p1:../../sysutils/amanda-common
-USE_PKGLIBTOOL= yes
GNU_CONFIGURE= yes
.include "../../mk/bsd.prefs.mk"
diff --git a/sysutils/amanda-client/pkg/PLIST b/sysutils/amanda-client/pkg/PLIST
index 58d361693e0..d4774145252 100644
--- a/sysutils/amanda-client/pkg/PLIST
+++ b/sysutils/amanda-client/pkg/PLIST
@@ -1,5 +1,6 @@
-@comment $NetBSD: PLIST,v 1.2 1999/04/04 23:34:45 tron Exp $
+@comment $NetBSD: PLIST,v 1.3 2000/08/17 02:26:28 wiz Exp $
lib/libamclient.a
+lib/libamclient.la
lib/libamclient-2.4.1p1.so.0.0
libexec/amandad
libexec/calcsize
diff --git a/sysutils/amanda-common/Makefile b/sysutils/amanda-common/Makefile
index 53c8899999b..8a2a74728c3 100644
--- a/sysutils/amanda-common/Makefile
+++ b/sysutils/amanda-common/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.9 2000/02/05 06:51:44 wiz Exp $
+# $NetBSD: Makefile,v 1.10 2000/08/17 02:26:28 wiz Exp $
# FreeBSD Id: Makefile,v 1.9 1997/03/08 05:00:11 gpalmer Exp
#
@@ -10,15 +10,25 @@ MASTER_SITES= ftp://ftp.cs.umd.edu/pub/amanda/
MAINTAINER= packages@netbsd.org
HOMEPAGE= http://www.amanda.org/
+DEINSTALL_FILE= ${WRKDIR}/DEINSTALL
+INSTALL_FILE= ${WRKDIR}/INSTALL
+
.include "../../mk/bsd.prefs.mk"
.include "../../sysutils/amanda-common/Makefile.common"
.if ${OPSYS} == "NetBSD"
-DEPENDS+= addnerd-1.6:../../sysutils/addnerd
-ADDUSER_PROG= ${PREFIX}/sbin/addnerd
+.if exists(/usr/sbin/user)
+ADDUSER= /usr/sbin/useradd
+ADDGROUP= /usr/sbin/groupadd
+.else
+DEPENDS+= user>=20000313:../../sysutils/user
+ADDUSER= ${LOCALBASE}/sbin/useradd
+ADDGROUP= ${LOCALBASE}/sbin/groupadd
+.endif
.elif ${OPSYS} == "SunOS"
-ADDUSER_PROG= useradd
MAKE_ENV+= CPPFLAGS=-D_LARGEFILE64_SOURCE
+ADDUSER= useradd
+ADDGROUP= groupadd
.endif
CONFIGURE_ARGS+= --without-server --without-restore --without-client
@@ -28,10 +38,13 @@ CPPFLAGS= # empty
BUILD_DEFS+= AMANDA_USER AMANDA_SMB AMANDA_VAR
pre-install:
- case `${GREP} -c '^${AMANDA_USER}:' /etc/passwd || ${TRUE}` in \
- 0) \
- ${SETENV} ${MAKE_ENV} ${ADDUSER_PROG} -g ${AMANDA_GROUP} ${AMANDA_USER} \
- ;; \
- esac
+ ${SED} -e 's|@AMUSER@|${AMANDA_USER}|g' \
+ < ${PKGDIR}/DEINSTALL > ${DEINSTALL_FILE}
+ ${SED} -e 's|@AMUSER@|${AMANDA_USER}|g' \
+ -e 's|@AMGROUP@|${AMANDA_GROUP}|g' \
+ -e 's|@ADDUSER@|${ADDUSER}|g' \
+ -e 's|@ADDGROUP@|${ADDGROUP}|g' \
+ < ${PKGDIR}/INSTALL > ${INSTALL_FILE}
+ PKG_PREFIX=${PREFIX} ${SH} ${INSTALL_FILE} ${PKGNAME} PRE-INSTALL
.include "../../mk/bsd.pkg.mk"
diff --git a/sysutils/amanda-common/Makefile.common b/sysutils/amanda-common/Makefile.common
index 4b7cb69ac43..8ebf1ecfee3 100644
--- a/sysutils/amanda-common/Makefile.common
+++ b/sysutils/amanda-common/Makefile.common
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.common,v 1.2 2000/06/01 11:23:41 rh Exp $
+# $NetBSD: Makefile.common,v 1.3 2000/08/17 02:26:29 wiz Exp $
#
# common make file fragment shared by all amanda-* pkgs.
#
@@ -12,7 +12,7 @@ AMANDA_GROUP= sysadmin
AMANDA_USER?= backup
AMANDA_VAR?= /var/amanda
-USE_PKGLIBTOOL= yes
+USE_LIBTOOL= yes
GNU_CONFIGURE= yes
CONFIGURE_ARGS+= --with-user=${AMANDA_USER} \
--with-group=${AMANDA_GROUP} \
diff --git a/sysutils/amanda-common/pkg/DEINSTALL b/sysutils/amanda-common/pkg/DEINSTALL
new file mode 100644
index 00000000000..e0456852ffa
--- /dev/null
+++ b/sysutils/amanda-common/pkg/DEINSTALL
@@ -0,0 +1,27 @@
+#!/bin/sh
+#
+# $NetBSD: DEINSTALL,v 1.1 2000/08/17 02:26:30 wiz Exp $
+#
+
+PKGNAME=$1
+STAGE=$2
+
+USER=@AMUSER@
+
+case ${STAGE} in
+DEINSTALL)
+ ;;
+POST-DEINSTALL)
+ cat << EOF
+===========================================================================
+If you won't be using ${PKGNAME} any longer, you may want to
+remove the \`${USER}' user.
+===========================================================================
+EOF
+ ;;
+*)
+ echo "Unexpected argument: $2"
+ exit 1
+ ;;
+esac
+exit 0
diff --git a/sysutils/amanda-common/pkg/INSTALL b/sysutils/amanda-common/pkg/INSTALL
new file mode 100644
index 00000000000..16c5f6d16b6
--- /dev/null
+++ b/sysutils/amanda-common/pkg/INSTALL
@@ -0,0 +1,45 @@
+#!/bin/sh
+#
+# $NetBSD: INSTALL,v 1.1 2000/08/17 02:26:31 wiz Exp $
+
+PKGNAME=$1
+STAGE=$2
+
+AMUSER=@AMUSER@
+AMGROUP=@AMGROUP@
+ADDUSER=@ADDUSER@
+ADDGROUP=@ADDGROUP@
+
+case ${STAGE} in
+PRE-INSTALL)
+ # Group... the default's shipped with NetBSD
+ # We need to check that ${AMGROUP} exists before adding the user.
+ #
+ if grep "^${AMGROUP}:" /etc/group
+ then
+ echo "Group '${AMGROUP}' already exists...proceeding."
+ else
+ echo "Creating '${AMGROUP}' group..."
+ ${ADDGROUP} ${AMGROUP}
+ echo "Done."
+ fi
+
+ # use finger to be able to use NIS, ...
+ #
+ if finger ${AMUSER} 2>&1 | grep >/dev/null "no such user"
+ then
+ echo "Creating '${AMUSER}' user..."
+ ${ADDUSER} -c "Amanda User" -g ${AMGROUP} -s /bin/sh ${AMUSER}
+ echo "Done."
+ else
+ echo "User '${AMUSER}' already exists...proceeding."
+ fi
+ ;;
+POST-INSTALL)
+ ;;
+*)
+ echo "Unexpected argument: $2"
+ exit 1
+ ;;
+esac
+exit 0
diff --git a/sysutils/amanda-common/pkg/PLIST b/sysutils/amanda-common/pkg/PLIST
index 4a2264d31ec..8f990d0dec8 100644
--- a/sysutils/amanda-common/pkg/PLIST
+++ b/sysutils/amanda-common/pkg/PLIST
@@ -1,7 +1,9 @@
-@comment $NetBSD: PLIST,v 1.2 1999/04/04 23:34:46 tron Exp $
+@comment $NetBSD: PLIST,v 1.3 2000/08/17 02:26:32 wiz Exp $
lib/libamanda.a
+lib/libamanda.la
lib/libamanda-2.4.1p1.so.0.0
lib/libamtape.a
+lib/libamtape.la
lib/libamtape-2.4.1p1.so.0.0
libexec/versionsuffix
man/man8/amanda.8
diff --git a/sysutils/amanda-server/pkg/PLIST b/sysutils/amanda-server/pkg/PLIST
index f1774c86438..cd1105cdfad 100644
--- a/sysutils/amanda-server/pkg/PLIST
+++ b/sysutils/amanda-server/pkg/PLIST
@@ -1,5 +1,6 @@
-@comment $NetBSD: PLIST,v 1.3 1999/09/06 18:16:35 bad Exp $
+@comment $NetBSD: PLIST,v 1.4 2000/08/17 02:26:33 wiz Exp $
lib/libamserver.a
+lib/libamserver.la
lib/libamserver-2.4.1p1.so.0.0
libexec/amidxtaped
libexec/amindexd