xref: /illumos-gate/usr/src/cmd/cmd-inet/usr.sbin/ipsecutils/Makefile (revision 3afe87ebb25691cb6d158edaa34a6fb9b703a691)
1e3320f40Smarkfen#
2e3320f40Smarkfen# CDDL HEADER START
3e3320f40Smarkfen#
4e3320f40Smarkfen# The contents of this file are subject to the terms of the
5e3320f40Smarkfen# Common Development and Distribution License (the "License").
6e3320f40Smarkfen# You may not use this file except in compliance with the License.
7e3320f40Smarkfen#
8e3320f40Smarkfen# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9e3320f40Smarkfen# or http://www.opensolaris.org/os/licensing.
10e3320f40Smarkfen# See the License for the specific language governing permissions
11e3320f40Smarkfen# and limitations under the License.
12e3320f40Smarkfen#
13e3320f40Smarkfen# When distributing Covered Code, include this CDDL HEADER in each
14e3320f40Smarkfen# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15e3320f40Smarkfen# If applicable, add the following below this CDDL HEADER, with the
16e3320f40Smarkfen# fields enclosed by brackets "[]" replaced with your own identifying
17e3320f40Smarkfen# information: Portions Copyright [yyyy] [name of copyright owner]
18e3320f40Smarkfen#
19e3320f40Smarkfen# CDDL HEADER END
20e3320f40Smarkfen#
21e3320f40Smarkfen#
22*3afe87ebSRoger A. Faulkner# Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
23e3320f40Smarkfen# Use is subject to license terms.
24e3320f40Smarkfen#
25e3320f40Smarkfen
26e3320f40SmarkfenPROG=		ikeadm ipsecalgs ipsecconf ipseckey ikecert
27e3320f40SmarkfenSOCKETPROG=	ipsecalgs ipsecconf ipseckey
28e3320f40SmarkfenSRCS=           ikeadm.c ipsecalgs.c ipsecconf.c ipseckey.c
29e3320f40Smarkfen
30e3320f40Smarkfeninclude ../../../Makefile.cmd
31e3320f40Smarkfen
32e3320f40SmarkfenMANIFEST=	ipsecalgs.xml policy.xml manual-key.xml
33e3320f40Smarkfen
34e3320f40SmarkfenROOTMANIFESTDIR=	$(ROOTSVCNETWORKIPSEC)
35e3320f40Smarkfen$(ROOTMANIFEST)		:= FILEMODE= 444
36e3320f40Smarkfeninclude ../../Makefile.cmd-inet
37e3320f40Smarkfen
38e3320f40SmarkfenCOMMONSRCS=	$(CMDINETCOMMONDIR)/$(COMMONOBJS:.o=.c)
39e3320f40SmarkfenSRCS+=		$(COMMONSRCS)
40e3320f40Smarkfen
41e3320f40Smarkfen#
42e3320f40Smarkfen# Message catalog
43e3320f40Smarkfen#
44e3320f40SmarkfenPOFILES=	ikeadm.po ipsecalgs.po ipsecconf.po ipseckey.po
45e3320f40SmarkfenPOFILE=		ipsecutils.po
46e3320f40Smarkfen
47e3320f40Smarkfenall:=		TARGET= all
48e3320f40Smarkfeninstall:=	TARGET= install
49e3320f40Smarkfenclean:=		TARGET= clean
50e3320f40Smarkfenclobber:=	TARGET= clobber
51e3320f40Smarkfenlint:=		TARGET= lint
52e3320f40Smarkfen
53e3320f40SmarkfenCLOBBERFILES +=	$(PROG) $(POFILES)
54e3320f40SmarkfenCLEANFILES += $(PROG) $(POFILES)
55e3320f40Smarkfen
56e3320f40SmarkfenCPPFLAGS +=     -DSYSV -DBSD_COMP -I$(CMDINETCOMMONDIR) -I.
57e3320f40Smarkfen
58e3320f40SmarkfenCFLAGS += $(XSTRCONST)
59e3320f40SmarkfenLDLIBS += -lipsecutil -lnsl
60e3320f40Smarkfen$(SOCKETPROG)	:=      LDLIBS += -lsocket
61e3320f40Smarkfen
62e3320f40Smarkfen.KEEP_STATE:
63e3320f40Smarkfen
64e3320f40Smarkfen.PARALLEL:
65e3320f40Smarkfen
66*3afe87ebSRoger A. Faulkner.NO_PARALLEL:	$(CHKMANIFEST)
67*3afe87ebSRoger A. Faulkner
68e3320f40Smarkfenall: $(PROG)
69e3320f40Smarkfen
70e3320f40Smarkfen#
71e3320f40Smarkfen# message catalog
72e3320f40Smarkfen#
73e3320f40Smarkfen
74e3320f40Smarkfen$(POFILE): $(POFILES)
75e3320f40Smarkfen	$(RM) $@
76e3320f40Smarkfen	cat $(POFILES) >> $@
77e3320f40Smarkfen
78e3320f40Smarkfen$(COMMONOBJS): $(COMMONSRCS)
79e3320f40Smarkfen	$(COMPILE.c) $(COMMONSRCS)
80e3320f40Smarkfen
81e3320f40Smarkfen$(ROOTUSRSBINLINKS):
82e3320f40Smarkfen	-$(RM) $@; $(SYMLINK) ../../sbin/$(@F) $@
83e3320f40Smarkfen
84e3320f40Smarkfeninstall: $(PROG) $(ROOTFS_PROG) .WAIT $(ROOTUSRSBINPROG) \
85e3320f40Smarkfen	 $(ROOTUSRSBINLINKS) $(ROOTETCDEFAULTFILES) $(ROOTMANIFEST)
86e3320f40Smarkfen
87e3320f40Smarkfenlint:
88e3320f40Smarkfen	$(LINT.c) -erroff=E_NAME_USED_NOT_DEF2 \
89e3320f40Smarkfen	-erroff=E_NAME_MULTIPLY_DEF2 $(SRCS) $(LDLIBS)
90e3320f40Smarkfen
91e3320f40Smarkfencheck:	$(CHKMANIFEST)
92e3320f40Smarkfen
93e3320f40Smarkfenclean:
94e3320f40Smarkfen	-$(RM) $(CLEANFILES)
95e3320f40Smarkfen
96e3320f40Smarkfen
97e3320f40Smarkfeninclude ../../../Makefile.targ
98e3320f40Smarkfen
99