xref: /illumos-gate/usr/src/cmd/flowstat/Makefile (revision d3b5f563)
10dc2366fSVenugopal Iyer#
20dc2366fSVenugopal Iyer# CDDL HEADER START
30dc2366fSVenugopal Iyer#
40dc2366fSVenugopal Iyer# The contents of this file are subject to the terms of the
50dc2366fSVenugopal Iyer# Common Development and Distribution License (the "License").
60dc2366fSVenugopal Iyer# You may not use this file except in compliance with the License.
70dc2366fSVenugopal Iyer#
80dc2366fSVenugopal Iyer# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
90dc2366fSVenugopal Iyer# or http://www.opensolaris.org/os/licensing.
100dc2366fSVenugopal Iyer# See the License for the specific language governing permissions
110dc2366fSVenugopal Iyer# and limitations under the License.
120dc2366fSVenugopal Iyer#
130dc2366fSVenugopal Iyer# When distributing Covered Code, include this CDDL HEADER in each
140dc2366fSVenugopal Iyer# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
150dc2366fSVenugopal Iyer# If applicable, add the following below this CDDL HEADER, with the
160dc2366fSVenugopal Iyer# fields enclosed by brackets "[]" replaced with your own identifying
170dc2366fSVenugopal Iyer# information: Portions Copyright [yyyy] [name of copyright owner]
180dc2366fSVenugopal Iyer#
190dc2366fSVenugopal Iyer# CDDL HEADER END
200dc2366fSVenugopal Iyer#
210dc2366fSVenugopal Iyer#
220dc2366fSVenugopal Iyer# Copyright 2010 Sun Microsystems, Inc.  All rights reserved.
230dc2366fSVenugopal Iyer# Use is subject to license terms.
240dc2366fSVenugopal Iyer#
255661bb76SJohn Levon# Copyright (c) 2018, Joyent, Inc.
260dc2366fSVenugopal Iyer
27e96f8419SYuri PankovPROG=flowstat
280dc2366fSVenugopal Iyer
290dc2366fSVenugopal IyerROOTFS_PROG= $(PROG)
300dc2366fSVenugopal Iyer
310dc2366fSVenugopal IyerPOFILE= $(PROG).po
320dc2366fSVenugopal Iyer
330dc2366fSVenugopal Iyerinclude ../Makefile.cmd
340dc2366fSVenugopal Iyer
350dc2366fSVenugopal IyerXGETFLAGS += -a -x $(PROG).xcl
360dc2366fSVenugopal IyerLDLIBS += -L$(ROOT)/lib
37e96f8419SYuri PankovLDLIBS += -ldladm -lofmt
380dc2366fSVenugopal Iyer
397014882cSRichard LoweCERRWARN += -_gcc=-Wno-implicit-function-declaration
40*d3b5f563SJohn LevonCERRWARN += $(CNOWARN_UNINIT)
417014882cSRichard Lowe
425661bb76SJohn Levon# not linted
435661bb76SJohn LevonSMATCH=off
445661bb76SJohn Levon
450dc2366fSVenugopal IyerROOTCFGDIR=	$(ROOTETC)/dladm
460dc2366fSVenugopal Iyer
470dc2366fSVenugopal Iyer.KEEP_STATE:
480dc2366fSVenugopal Iyer
49e96f8419SYuri Pankovall: $(ROOTFS_PROG)
500dc2366fSVenugopal Iyer
510dc2366fSVenugopal Iyer#
520dc2366fSVenugopal Iyer# Message catalog
530dc2366fSVenugopal Iyer#
540dc2366fSVenugopal Iyer_msg: $(POFILE)
550dc2366fSVenugopal Iyer
560dc2366fSVenugopal Iyer$(POFILE): $(PROG).c
570dc2366fSVenugopal Iyer	$(RM) $@
580dc2366fSVenugopal Iyer	$(COMPILE.cpp) $(PROG).c > $(POFILE).i
590dc2366fSVenugopal Iyer	$(XGETTEXT) $(XGETFLAGS) $(POFILE).i
600dc2366fSVenugopal Iyer	sed "/^domain/d" messages.po > $@
610dc2366fSVenugopal Iyer	$(RM) messages.po $(POFILE).i
620dc2366fSVenugopal Iyer
630dc2366fSVenugopal Iyerinstall: all $(ROOTSBINPROG) $(ROOTCFGDIR)
640dc2366fSVenugopal Iyer	$(RM) $(ROOTUSRSBINPROG)
650dc2366fSVenugopal Iyer	-$(SYMLINK) ../../sbin/$(PROG) $(ROOTUSRSBINPROG)
660dc2366fSVenugopal Iyer
670dc2366fSVenugopal Iyerclean:
680dc2366fSVenugopal Iyer
690dc2366fSVenugopal Iyerlint:	lint_PROG
700dc2366fSVenugopal Iyer
710dc2366fSVenugopal Iyer$(ROOTCFGDIR):
720dc2366fSVenugopal Iyer	$(INS.dir)
730dc2366fSVenugopal Iyer
740dc2366fSVenugopal Iyer$(ROOTCFGDIR)/%: $(ROOTCFGDIR) %
750dc2366fSVenugopal Iyer	$(INS.file)
760dc2366fSVenugopal Iyer
770dc2366fSVenugopal Iyerinclude ../Makefile.targ
78