xref: /illumos-gate/usr/src/cmd/connstat/Makefile (revision 1da57d551424de5a9d469760be7c4b4d4f10a755)
1#
2# CDDL HEADER START
3#
4# This file and its contents are supplied under the terms of the
5# Common Development and Distribution License ("CDDL"), version 1.0.
6# You may only use this file in accordance with the terms of version
7# 1.0 of the CDDL.
8#
9# A full copy of the text of the CDDL should have accompanied this
10# source.  A copy of the CDDL is also available via the Internet at
11# http://www.illumos.org/license/CDDL.
12#
13# CDDL HEADER END
14#
15#
16# Copyright (c) 2015 by Delphix. All rights reserved.
17#
18
19PROG=	connstat
20OBJS=	connstat_main.o connstat_mib.o connstat_tcp.o
21SRCS=	$(OBJS:%.o=%.c)
22POFILES= connstat_main.po connstat_tcp.po connstat_mib.po
23POFILE=	connstat.po
24
25include ../Makefile.cmd
26include ../Makefile.ctf
27
28CSTD= $(CSTD_GNU99)
29LDLIBS += -lsocket -lnsl -lumem -lofmt
30XGETFLAGS += -a -x $(PROG).xcl
31
32.KEEP_STATE:
33
34all: $(PROG)
35
36$(PROG): $(OBJS)
37	$(LINK.c) -o $@ $(OBJS) $(LDLIBS)
38	$(POST_PROCESS)
39
40$(POFILE): $(POFILES)
41	$(RM) $@
42	cat $(POFILES) > $@
43
44install: all $(ROOTPROG)
45
46clean:
47	$(RM) $(OBJS)
48
49lint:   lint_SRCS
50
51include ../Makefile.targ
52