summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorru <ru@FreeBSD.org>2004-03-12 13:20:24 +0000
committerru <ru@FreeBSD.org>2004-03-12 13:20:24 +0000
commit893c24a298eadb63163b3c826cbda388a8d9a589 (patch)
tree0a2cb02486c448963122d557f461000f6441ac75
parent37f2e4ca225f38ae51882b1298d8a3da10b19d12 (diff)
downloadFreeBSD-src-893c24a298eadb63163b3c826cbda388a8d9a589.zip
FreeBSD-src-893c24a298eadb63163b3c826cbda388a8d9a589.tar.gz
Use find(1) instead of ``pw groupshow'' to detect missing groups.
Restore checks for recently added PF groups. Reviewed by: mlaier
-rw-r--r--Makefile.inc130
1 files changed, 18 insertions, 12 deletions
diff --git a/Makefile.inc1 b/Makefile.inc1
index 943831f..2ff3ff6 100644
--- a/Makefile.inc1
+++ b/Makefile.inc1
@@ -407,23 +407,29 @@ sparc64_installcheck:
#
# Checks to be sure system is ready for installworld
#
-installcheck: ${SPECIAL_INSTALLCHECKS}
+CHECK_UIDS=
+CHECK_GIDS=
.if !defined(NO_SENDMAIL)
- @if ! `id -u smmsp > /dev/null`; then \
- echo "ERROR: Required smmsp user is missing, see /usr/src/UPDATING."; \
- false; \
- fi
- @if ! `pw groupshow smmsp > /dev/null`; then \
- echo "ERROR: Required smmsp group is missing, see /usr/src/UPDATING."; \
- false; \
- fi
+CHECK_UIDS+= smmsp
+CHECK_GIDS+= smmsp
.endif
.if !defined(NO_PF)
- @if ! `id -u proxy > /dev/null`; then \
- echo "ERROR: Required proxy user is missing, see /usr/src/UPDATING."; \
+CHECK_UIDS+= proxy
+CHECK_GIDS+= proxy authpf
+.endif
+installcheck: ${SPECIAL_INSTALLCHECKS}
+.for uid in ${CHECK_UIDS}
+ @if ! `id -u ${uid} > /dev/null`; then \
+ echo "ERROR: Required ${uid} user is missing, see /usr/src/UPDATING."; \
false; \
fi
-.endif
+.endfor
+.for gid in ${CHECK_GIDS}
+ @if ! `find / -prune -group ${gid} > /dev/null`; then \
+ echo "ERROR: Required ${gid} group is missing, see /usr/src/UPDATING."; \
+ false; \
+ fi
+.endfor
#
# distributeworld
OpenPOWER on IntegriCloud