about summary refs log tree commit diff
path: root/nss/db-Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'nss/db-Makefile')
-rw-r--r--nss/db-Makefile10
1 files changed, 9 insertions, 1 deletions
diff --git a/nss/db-Makefile b/nss/db-Makefile
index 55edd66c01..756f4c6ce6 100644
--- a/nss/db-Makefile
+++ b/nss/db-Makefile
@@ -1,5 +1,5 @@
 DATABASES = $(wildcard /etc/passwd /etc/group /etc/ethers /etc/protocols \
-		       /etc/rpc /etc/services /etc/shadow)
+		       /etc/rpc /etc/services /etc/shadow /etc/netgroup)
 
 VAR_DB = /var/db
 
@@ -67,3 +67,11 @@ $(VAR_DB)/shadow.db: /etc/shadow
 		 /^[^#]/ { printf ".%s ", $$1; print }' $^ | \
 	$(MAKEDB) -o $@ -
 	@echo "done."
+
+$(VAR_DB)/netgroup.db: /etc/netgroup
+	@echo -n "$(patsubst %.db,%,$(@F))... "
+	@$(AWK) '/^[^#]/ { end=sub(/\\/, " "); \
+			   gsub(/[ \t]+/, " "); \
+			   if(end == 1) printf "%s", $$0; else print }' $^ | \
+	$(MAKEDB) -o $@ -
+	@echo "done."