ypserv/ypserv-2.13-nonedomain.patch
2008-02-04 14:44:27 +00:00

23 lines
813 B
Diff

diff -up ypserv-2.19/scripts/ypMakefile.in_old ypserv-2.19/scripts/ypMakefile.in
--- ypserv-2.19/scripts/ypMakefile.in_old 2008-02-04 15:26:47.000000000 +0100
+++ ypserv-2.19/scripts/ypMakefile.in 2008-02-04 15:27:12.000000000 +0100
@@ -98,10 +98,18 @@ NETMASKS = $(YPSRCDIR)/netmasks
YPSERVERS = $(YPDIR)/ypservers # List of all NIS servers for a domain
target: Makefile
+ifeq ($(shell /bin/domainname), (none))
+ @echo "Domain name cannot be (none)"
+else
+ifeq ($(shell /bin/domainname), )
+ @echo "Domain name must be set"
+else
@test ! -d $(LOCALDOMAIN) && mkdir $(LOCALDOMAIN) ; \
cd $(LOCALDOMAIN) ; \
$(NOPUSH) || $(MAKE) -f ../Makefile ypservers; \
$(MAKE) -f ../Makefile all
+endif
+endif
# If you don't want some of these maps built, feel free to comment
# them out from this list.