1 # 2 # CDDL HEADER START 3 # 4 # The contents of this file are subject to the terms of the 5 # Common Development and Distribution License (the "License"). 6 # You may not use this file except in compliance with the License. 7 # 8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 9 # or http://www.opensolaris.org/os/licensing. 10 # See the License for the specific language governing permissions 11 # and limitations under the License. 12 # 13 # When distributing Covered Code, include this CDDL HEADER in each 14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE. 15 # If applicable, add the following below this CDDL HEADER, with the 16 # fields enclosed by brackets "[]" replaced with your own identifying 17 # information: Portions Copyright [yyyy] [name of copyright owner] 18 # 19 # CDDL HEADER END 20 # 21 # Copyright 2009 Sun Microsystems, Inc. All rights reserved. 22 # Use is subject to license terms. 23 24 SYMPROG= hosts inetd.conf networks protocols services netmasks sock2path 25 26 # New /etc/inet files shouldn't have /etc entries. 27 EDITPROG= ipaddrsel.conf ipsecalgs 28 PROG= datemsk.ndpd ipsecinit.sample ipqosconf.1.sample ipqosconf.2.sample \ 29 ipqosconf.3.sample wanboot.conf.sample 30 ETCPROG= $(SYMPROG) $(EDITPROG) $(PROG) 31 SUBDIRS= default dhcp init.d ike nca ppp secret 32 33 include ../../Makefile.cmd 34 35 all:= TARGET= all 36 install:= TARGET= install 37 38 ROOTVAR= $(ROOT)/var 39 INETETCDIR= $(ROOTETC)/inet 40 INETVARDIR= $(ROOTVAR)/inet 41 DIRS= $(INETETCDIR) $(INETVARDIR) 42 SYMDIR= inet 43 ETCINETPROG= $(ETCPROG:%=$(INETETCDIR)/%) 44 EDITFILES= $(SYMPROG:%=$(INETETCDIR)/%) $(EDITPROG:%=$(INETETCDIR)/%) 45 # Only old /etc/inet files get symlinks in /etc. 46 SYMETCPROG= $(SYMPROG:%=sym_%) 47 SYMIPNODES= $(INETETCDIR)/ipnodes 48 49 FILEMODE= 0444 50 51 .KEEP_STATE: 52 53 $(EDITFILES) := FILEMODE= 0644 54 55 all: $(ETCPROG) $(SUBDIRS) 56 57 install: all $(DIRS) $(ETCINETPROG) $(SYMETCPROG) $(SYMIPNODES) $(SUBDIRS) 58 59 $(SYMIPNODES) : 60 $(RM) $@ 61 $(SYMLINK) ./hosts $@ 62 63 $(INETETCDIR)/% : % 64 $(INS.file) 65 66 sym_% : % 67 $(RM) $(ROOTETC)/$< 68 $(SYMLINK) $(SYMDIR)/$< $(ROOTETC)/$< 69 70 $(DIRS): 71 $(INS.dir) 72 73 $(SUBDIRS): FRC $(DIRS) 74 @cd $@; pwd; $(MAKE) $(TARGET) 75 76 FRC: 77 78 # datemsk.ndpd is generated from datemsk.template because of a side-effect of 79 # SCCS. Some of the datemsk.ndpd format strings include "%<letter>%", which 80 # SCCS confuses for ID keywords. datemsk.template should quote the "%" 81 # with "\" and code below will filter out the "\". Only datemsk.ndpd format 82 # strings next to each other need to be quoted. 83 84 datemsk.ndpd: datemsk.template 85 @while read i; do echo $$i; done < datemsk.template > $@ 86 87 clean clobber: 88 $(RM) datemsk.ndpd 89 90 lint: 91