xref: /titanic_52/usr/src/cmd/cmd-inet/lib/nwamd/Makefile (revision 7014882c6a3672fd0e5d60200af8643ae53c5928)
1d71dbb73Sjbeck#
2d71dbb73Sjbeck# CDDL HEADER START
3d71dbb73Sjbeck#
4d71dbb73Sjbeck# The contents of this file are subject to the terms of the
5d71dbb73Sjbeck# Common Development and Distribution License (the "License").
6d71dbb73Sjbeck# You may not use this file except in compliance with the License.
7d71dbb73Sjbeck#
8d71dbb73Sjbeck# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9d71dbb73Sjbeck# or http://www.opensolaris.org/os/licensing.
10d71dbb73Sjbeck# See the License for the specific language governing permissions
11d71dbb73Sjbeck# and limitations under the License.
12d71dbb73Sjbeck#
13d71dbb73Sjbeck# When distributing Covered Code, include this CDDL HEADER in each
14d71dbb73Sjbeck# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15d71dbb73Sjbeck# If applicable, add the following below this CDDL HEADER, with the
16d71dbb73Sjbeck# fields enclosed by brackets "[]" replaced with your own identifying
17d71dbb73Sjbeck# information: Portions Copyright [yyyy] [name of copyright owner]
18d71dbb73Sjbeck#
19d71dbb73Sjbeck# CDDL HEADER END
20d71dbb73Sjbeck#
21d71dbb73Sjbeck#
22ef810481SRenee Danson Sommerfeld# Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
23d71dbb73Sjbeck#
24d71dbb73Sjbeck# usr/src/cmd/cmd-inet/lib/nwamd/Makefile
25d71dbb73Sjbeck#
26d71dbb73Sjbeck
27d71dbb73Sjbeck# Needed for ROOTFS_LIBDIR definition
28d71dbb73Sjbeckinclude		../../../../lib/Makefile.lib
29d71dbb73Sjbeck
30d71dbb73SjbeckPROG=		nwamd
316ba597c5SAnurag S. MaskeyOBJS=		conditions.o dlpi_events.o door_if.o enm.o\
326ba597c5SAnurag S. Maskey		events.o known_wlans.o llp.o loc.o logging.o\
336ba597c5SAnurag S. Maskey		main.o ncp.o ncu.o ncu_phys.o ncu_ip.o objects.o\
346ba597c5SAnurag S. Maskey		routing_events.o sysevent_events.o util.o
35d71dbb73SjbeckSRCS=		$(OBJS:%.o=%.c)
366ba597c5SAnurag S. MaskeyHEADERS=	conditions.h events.h known_wlans.h llp.h ncp.h ncu.h\
376ba597c5SAnurag S. Maskey		objects.h
386ba597c5SAnurag S. MaskeyLOCFILES=	create_loc_auto create_loc_nonet
396ba597c5SAnurag S. MaskeyNONETLOCFILES=	ipf.conf.dfl ipf6.conf.dfl
406ba597c5SAnurag S. Maskey
416ba597c5SAnurag S. MaskeyROOTCFGDIR=	$(ROOTETC)/nwam
426ba597c5SAnurag S. MaskeyROOTLOCDIR=	$(ROOTCFGDIR)/loc
436ba597c5SAnurag S. MaskeyNONETLOCDIR=	$(ROOTLOCDIR)/NoNet
446ba597c5SAnurag S. MaskeyLOCDIRS=	$(NONETLOCDIR)
456ba597c5SAnurag S. MaskeyROOTCFGFILES=	$(LOCFILES:%=$(ROOTLOCDIR)/%) \
466ba597c5SAnurag S. Maskey		$(NONETLOCFILES:%=$(NONETLOCDIR)/%)
47d71dbb73Sjbeck
48d71dbb73Sjbeckinclude		../../../Makefile.cmd
49d71dbb73Sjbeck
506ba597c5SAnurag S. Maskey$(ROOTCFGFILES) := FILEMODE= 644
516ba597c5SAnurag S. Maskey
52d71dbb73SjbeckROOTCMDDIR=	$(ROOTFS_LIBDIR)/inet
53d71dbb73Sjbeck
546ba597c5SAnurag S. MaskeyLDLIBS +=	-ldhcpagent -ldhcputil -ldladm -ldlpi -lgen \
55f6da83d4SAnurag S. Maskey		-linetutil -lipadm -lkstat -lnsl -lnvpair -lnwam \
566ba597c5SAnurag S. Maskey		-lsecdb -lscf -lsocket -lsysevent -lumem -luutil
576ba597c5SAnurag S. Maskey
58*7014882cSRichard LoweCERRWARN +=	-_gcc=-Wno-uninitialized
59*7014882cSRichard LoweCERRWARN +=	-_gcc=-Wno-parentheses
60*7014882cSRichard LoweCERRWARN +=	-_gcc=-Wno-switch
61*7014882cSRichard LoweCERRWARN +=	-_gcc=-Wno-unused-label
62*7014882cSRichard Lowe
636ba597c5SAnurag S. Maskey#
646ba597c5SAnurag S. Maskey# Instrument with CTF data to ease debugging.
656ba597c5SAnurag S. Maskey#
666ba597c5SAnurag S. MaskeyCTFCONVERT_HOOK = && $(CTFCONVERT_O)
676ba597c5SAnurag S. MaskeyCTFMERGE_HOOK = && $(CTFMERGE) -L VERSION -o $@ $(OBJS)
686ba597c5SAnurag S. Maskey$(OBJS) := CFLAGS += $(CTF_FLAGS)
69d71dbb73Sjbeck
70d71dbb73Sjbeck.KEEP_STATE:
71d71dbb73Sjbeck
72d71dbb73Sjbeck.PARALLEL:
73d71dbb73Sjbeck
74d71dbb73Sjbeckall: $(PROG)
75d71dbb73Sjbeck
76d71dbb73Sjbeck$(PROG): $(OBJS)
776ba597c5SAnurag S. Maskey	$(LINK.c) $(OBJS) -o $@ $(LDLIBS) $(CTFMERGE_HOOK)
78d71dbb73Sjbeck	$(POST_PROCESS)
79d71dbb73Sjbeck
806ba597c5SAnurag S. Maskeyinstall: $(ROOTCMD) $(ROOTLOCDIR) $(ROOTCFGFILES)
81d71dbb73Sjbeck
82d71dbb73Sjbeckcheck:  $(SRCS) $(HEADERS)
83d71dbb73Sjbeck	$(CSTYLE) -cpP $(SRCS) $(HEADERS)
84d71dbb73Sjbeck
856ba597c5SAnurag S. Maskey$(ROOTCMD): all
86d71dbb73Sjbeck
87d71dbb73Sjbeckclean:
88d71dbb73Sjbeck	$(RM) $(OBJS)
89d71dbb73Sjbeck
90d71dbb73Sjbecklint:	lint_SRCS
91d71dbb73Sjbeck
926ba597c5SAnurag S. Maskey$(ROOTCFGDIR):
936ba597c5SAnurag S. Maskey	$(INS.dir)
946ba597c5SAnurag S. Maskey
956ba597c5SAnurag S. Maskey$(ROOTLOCDIR): $(ROOTCFGDIR)
966ba597c5SAnurag S. Maskey	$(INS.dir)
976ba597c5SAnurag S. Maskey
986ba597c5SAnurag S. Maskey$(LOCDIRS): $(ROOTLOCDIR)
996ba597c5SAnurag S. Maskey	$(INS.dir)
1006ba597c5SAnurag S. Maskey
1016ba597c5SAnurag S. Maskey$(ROOTLOCDIR)/%: $(ROOTLOCDIR) %
1026ba597c5SAnurag S. Maskey	$(INS.file)
1036ba597c5SAnurag S. Maskey
1046ba597c5SAnurag S. Maskey$(NONETLOCDIR)/%: $(NONETLOCDIR) %
1056ba597c5SAnurag S. Maskey	$(INS.file)
1066ba597c5SAnurag S. Maskey
107d71dbb73Sjbeckinclude		../../../Makefile.targ
108