xref: /illumos-gate/usr/src/lib/libresolv2/Makefile (revision 7c478bd9)
1*7c478bd9Sstevel@tonic-gate#
2*7c478bd9Sstevel@tonic-gate# Copyright 2004 Sun Microsystems, Inc.  All rights reserved.
3*7c478bd9Sstevel@tonic-gate# Use is subject to license terms.
4*7c478bd9Sstevel@tonic-gate#
5*7c478bd9Sstevel@tonic-gate# ident	"%Z%%M%	%I%	%E% SMI"
6*7c478bd9Sstevel@tonic-gate#
7*7c478bd9Sstevel@tonic-gate# lib/libresolv2/Makefile
8*7c478bd9Sstevel@tonic-gate#
9*7c478bd9Sstevel@tonic-gate
10*7c478bd9Sstevel@tonic-gateinclude		../../Makefile.master
11*7c478bd9Sstevel@tonic-gateinclude		../Makefile.lib
12*7c478bd9Sstevel@tonic-gate
13*7c478bd9Sstevel@tonic-gateMANIFEST=	client.xml
14*7c478bd9Sstevel@tonic-gateMANIFESTDIR=	$(ROOT)/var/svc/manifest/network/dns
15*7c478bd9Sstevel@tonic-gateROOTMANIFEST=	$(MANIFEST:%=$(MANIFESTDIR)/%)
16*7c478bd9Sstevel@tonic-gate
17*7c478bd9Sstevel@tonic-gate$(ROOTMANIFEST) :=	FILEMODE = 444
18*7c478bd9Sstevel@tonic-gate$(ROOTMANIFEST) :=	OWNER = root
19*7c478bd9Sstevel@tonic-gate$(ROOTMANIFEST) :=	GROUP = bin
20*7c478bd9Sstevel@tonic-gate
21*7c478bd9Sstevel@tonic-gateCHKMANIFEST=	$(MANIFEST:%.xml=%.xmlchk)
22*7c478bd9Sstevel@tonic-gate
23*7c478bd9Sstevel@tonic-gateSUBDIRS=	include spec $(MACH)
24*7c478bd9Sstevel@tonic-gate$(BUILD64)SUBDIRS +=	$(MACH64)
25*7c478bd9Sstevel@tonic-gateSUBDIRS +=	.WAIT irs
26*7c478bd9Sstevel@tonic-gate
27*7c478bd9Sstevel@tonic-gate# EXPORT DELETE START
28*7c478bd9Sstevel@tonic-gate# CRYPT DELETE START
29*7c478bd9Sstevel@tonic-gateSUBDIRS +=	cylink dnssafe
30*7c478bd9Sstevel@tonic-gate# CRYPT DELETE END
31*7c478bd9Sstevel@tonic-gate# EXPORT DELETE END
32*7c478bd9Sstevel@tonic-gate
33*7c478bd9Sstevel@tonic-gateall :=		TARGET= all
34*7c478bd9Sstevel@tonic-gateclean :=	TARGET= clean
35*7c478bd9Sstevel@tonic-gateclobber :=	TARGET= clobber
36*7c478bd9Sstevel@tonic-gateinstall :=	TARGET= install
37*7c478bd9Sstevel@tonic-gatelint :=		TARGET= lint
38*7c478bd9Sstevel@tonic-gate_msg :=		TARGET= _msg
39*7c478bd9Sstevel@tonic-gate
40*7c478bd9Sstevel@tonic-gateLIBRARY= 	libresolv.a
41*7c478bd9Sstevel@tonic-gateTEXT_DOMAIN=	SUNW_OST_OSLIB
42*7c478bd9Sstevel@tonic-gateXGETFLAGS=	-a
43*7c478bd9Sstevel@tonic-gatePOFILE=		$(LIBRARY:.a=.po)
44*7c478bd9Sstevel@tonic-gatePOFILES=	generic.po
45*7c478bd9Sstevel@tonic-gate
46*7c478bd9Sstevel@tonic-gateSED=	sed
47*7c478bd9Sstevel@tonic-gateGREP=	grep
48*7c478bd9Sstevel@tonic-gateCP=	cp
49*7c478bd9Sstevel@tonic-gate
50*7c478bd9Sstevel@tonic-gate.KEEP_STATE:
51*7c478bd9Sstevel@tonic-gate
52*7c478bd9Sstevel@tonic-gateall clean clobber lint: $(SUBDIRS)
53*7c478bd9Sstevel@tonic-gate
54*7c478bd9Sstevel@tonic-gateinstall: $(SUBDIRS) $(ROOTMANIFEST)
55*7c478bd9Sstevel@tonic-gate
56*7c478bd9Sstevel@tonic-gate$(ROOTMANIFEST): $(MANIFESTDIR)
57*7c478bd9Sstevel@tonic-gate
58*7c478bd9Sstevel@tonic-gate$(MANIFESTDIR):
59*7c478bd9Sstevel@tonic-gate	$(INS.dir)
60*7c478bd9Sstevel@tonic-gate
61*7c478bd9Sstevel@tonic-gate$(MANIFESTDIR)/%: %
62*7c478bd9Sstevel@tonic-gate	$(INS.file)
63*7c478bd9Sstevel@tonic-gate
64*7c478bd9Sstevel@tonic-gate# install rule for install_h target
65*7c478bd9Sstevel@tonic-gate$(ROOTHDRDIR)/%: %
66*7c478bd9Sstevel@tonic-gate	$(INS.file)
67*7c478bd9Sstevel@tonic-gate
68*7c478bd9Sstevel@tonic-gateinstall_h: $(ROOTHDRS)
69*7c478bd9Sstevel@tonic-gate
70*7c478bd9Sstevel@tonic-gatecheck: $(CHECKHDRS) $(CHKMANIFEST)
71*7c478bd9Sstevel@tonic-gate
72*7c478bd9Sstevel@tonic-gate# EXPORT DELETE START
73*7c478bd9Sstevel@tonic-gate# CRYPT DELETE START
74*7c478bd9Sstevel@tonic-gate# Special targets to clean up the source tree for export distribution
75*7c478bd9Sstevel@tonic-gate# Warning: These target change the source tree
76*7c478bd9Sstevel@tonic-gateEXPORT_SRC:
77*7c478bd9Sstevel@tonic-gate	$(RM) Makefile+
78*7c478bd9Sstevel@tonic-gate	$(SED) -e "/^# EXPORT DELETE START/,/^# EXPORT DELETE END/d" \
79*7c478bd9Sstevel@tonic-gate		< Makefile > Makefile+
80*7c478bd9Sstevel@tonic-gate	$(MV) Makefile+ Makefile
81*7c478bd9Sstevel@tonic-gate	$(CHMOD) 444 Makefile
82*7c478bd9Sstevel@tonic-gate	/usr/bin/find cylink dnssafe common/cylink common/dnssafe \
83*7c478bd9Sstevel@tonic-gate		-name SCCS -prune -o -type f -exec $(RM) {} \;
84*7c478bd9Sstevel@tonic-gate
85*7c478bd9Sstevel@tonic-gateCRYPT_SRC:
86*7c478bd9Sstevel@tonic-gate	$(RM) Makefile+
87*7c478bd9Sstevel@tonic-gate	$(SED) -e "/^# CRYPT DELETE START/,/^# CRYPT DELETE END/d" \
88*7c478bd9Sstevel@tonic-gate		< Makefile > Makefile+
89*7c478bd9Sstevel@tonic-gate	$(MV) Makefile+ Makefile
90*7c478bd9Sstevel@tonic-gate	$(CHMOD) 444 Makefile
91*7c478bd9Sstevel@tonic-gate	/usr/bin/find cylink dnssafe common/cylink common/dnssafe \
92*7c478bd9Sstevel@tonic-gate		-name SCCS -prune -o -type f -exec $(RM) {} \;
93*7c478bd9Sstevel@tonic-gate
94*7c478bd9Sstevel@tonic-gate# CRYPT DELETE END
95*7c478bd9Sstevel@tonic-gate# EXPORT DELETE END
96*7c478bd9Sstevel@tonic-gate
97*7c478bd9Sstevel@tonic-gate_msg:	$(MSGDOMAIN) $(POFILE)
98*7c478bd9Sstevel@tonic-gate	$(RM) $(MSGDOMAIN)/$(POFILE)
99*7c478bd9Sstevel@tonic-gate	$(CP) $(POFILE) $(MSGDOMAIN)
100*7c478bd9Sstevel@tonic-gate
101*7c478bd9Sstevel@tonic-gate$(POFILE):	$(POFILES)
102*7c478bd9Sstevel@tonic-gate	$(RM) $@
103*7c478bd9Sstevel@tonic-gate	$(CAT) $(POFILES) > $@
104*7c478bd9Sstevel@tonic-gate
105*7c478bd9Sstevel@tonic-gate$(POFILES):
106*7c478bd9Sstevel@tonic-gate	$(RM) messages.po
107*7c478bd9Sstevel@tonic-gate	$(XGETTEXT) $(XGETFLAGS) *.[ch]* */*.[ch]*
108*7c478bd9Sstevel@tonic-gate	$(SED) -e '/^# msg/d' -e '/^domain/d' messages.po > $@
109*7c478bd9Sstevel@tonic-gate	$(RM) messages.po
110*7c478bd9Sstevel@tonic-gate
111*7c478bd9Sstevel@tonic-gate$(SUBDIRS): FRC
112*7c478bd9Sstevel@tonic-gate	@cd $@; pwd; $(MAKE) $(TARGET); echo
113*7c478bd9Sstevel@tonic-gate
114*7c478bd9Sstevel@tonic-gateFRC:
115