xref: /titanic_44/usr/src/test/os-tests/tests/spoof-ras/Makefile (revision 1aec9edfc2217cc2195a30b51c013bfe7717002f)
1*1aec9edfSCody Peter Mello#
2*1aec9edfSCody Peter Mello# This file and its contents are supplied under the terms of the
3*1aec9edfSCody Peter Mello# Common Development and Distribution License ("CDDL"), version 1.0.
4*1aec9edfSCody Peter Mello# You may only use this file in accordance with the terms of version
5*1aec9edfSCody Peter Mello# 1.0 of the CDDL.
6*1aec9edfSCody Peter Mello#
7*1aec9edfSCody Peter Mello# A full copy of the text of the CDDL should have accompanied this
8*1aec9edfSCody Peter Mello# source.  A copy of the CDDL is also available via the Internet at
9*1aec9edfSCody Peter Mello# http://www.illumos.org/license/CDDL.
10*1aec9edfSCody Peter Mello#
11*1aec9edfSCody Peter Mello
12*1aec9edfSCody Peter Mello#
13*1aec9edfSCody Peter Mello# Copyright (c) 2015 by Joyent, Inc. All rights reserved.
14*1aec9edfSCody Peter Mello#
15*1aec9edfSCody Peter Mello
16*1aec9edfSCody Peter Melloinclude $(SRC)/cmd/Makefile.cmd
17*1aec9edfSCody Peter Melloinclude $(SRC)/test/Makefile.com
18*1aec9edfSCody Peter Mello
19*1aec9edfSCody Peter MelloPROG = spoof-ras
20*1aec9edfSCody Peter MelloOBJS = $(PROG:%=%.o)
21*1aec9edfSCody Peter MelloSRCS = $(OBJS:%.o=%.c)
22*1aec9edfSCody Peter Mello
23*1aec9edfSCody Peter MelloLDLIBS += -lsocket -lnsl
24*1aec9edfSCody Peter MelloC99MODE = -xc99=%all
25*1aec9edfSCody Peter Mello
26*1aec9edfSCody Peter MelloROOTOPTPKG = $(ROOT)/opt/os-tests
27*1aec9edfSCody Peter MelloTESTDIR = $(ROOTOPTPKG)/tests
28*1aec9edfSCody Peter Mello
29*1aec9edfSCody Peter MelloCMDS = $(PROG:%=$(TESTDIR)/%)
30*1aec9edfSCody Peter Mello$(CMDS) := FILEMODE = 0555
31*1aec9edfSCody Peter Mello
32*1aec9edfSCody Peter Melloall: $(PROG)
33*1aec9edfSCody Peter Mello
34*1aec9edfSCody Peter Mello$(PROG): $(OBJS)
35*1aec9edfSCody Peter Mello	$(LINK.c) $(OBJS) -o $@ $(LDLIBS)
36*1aec9edfSCody Peter Mello	$(POST_PROCESS)
37*1aec9edfSCody Peter Mello
38*1aec9edfSCody Peter Mello%.o: ../%.c
39*1aec9edfSCody Peter Mello	$(COMPILE.c) $<
40*1aec9edfSCody Peter Mello
41*1aec9edfSCody Peter Melloinstall: all $(CMDS)
42*1aec9edfSCody Peter Mello
43*1aec9edfSCody Peter Mellolint: lint_SRCS
44*1aec9edfSCody Peter Mello
45*1aec9edfSCody Peter Melloclobber: clean
46*1aec9edfSCody Peter Mello	-$(RM) $(PROG)
47*1aec9edfSCody Peter Mello
48*1aec9edfSCody Peter Melloclean:
49*1aec9edfSCody Peter Mello	-$(RM) $(OBJS)
50*1aec9edfSCody Peter Mello
51*1aec9edfSCody Peter Mello$(CMDS): $(TESTDIR) $(PROG)
52*1aec9edfSCody Peter Mello
53*1aec9edfSCody Peter Mello$(TESTDIR):
54*1aec9edfSCody Peter Mello	$(INS.dir)
55*1aec9edfSCody Peter Mello
56*1aec9edfSCody Peter Mello$(TESTDIR)/%: %
57*1aec9edfSCody Peter Mello	$(INS.file)
58