1 #
2 # This file and its contents are supplied under the terms of the
3 # Common Development and Distribution License ("CDDL"), version 1.0.
4 # You may only use this file in accordance with the terms of version
5 # 1.0 of the CDDL.
6 #
7 # A full copy of the text of the CDDL should have accompanied this
8 # source. A copy of the CDDL is also available via the Internet at
9 # http://www.illumos.org/license/CDDL.
10 #
11
12 #
13 # Copyright (c) 2014 Joyent, Inc.
14 # Copyright 2017 Gordon W. Ross
15 #
16
17 # OAM User Test program
18 PROG= oamu_defs oamu_uakey
19 TESTS= oamu_01 oamu_02 oamu_03
20
21 include $(SRC)/cmd/Makefile.cmd
22
23 ROOTOPTPKG = $(ROOT)/opt/util-tests
24 ROOTCMDDIR = $(ROOTOPTPKG)/bin
25 TESTDIR = $(ROOTOPTPKG)/tests/libuserdefs
26 ROOTTESTS = $(TESTS:%=$(TESTDIR)/%)
27
28 LDLIBS += -luserdefs
29
30 all: $(PROG)
31
32 install: $(ROOTCMD) $(ROOTTESTS)
33 $(ROOTTESTS) : $(TESTDIR)
34 $(ROOTCMD) : $(PROG)
35
36 clean:
37
38 # lint_PROG doesn't handle multiple programs...
39 lint:
40 for p in $(PROG); do \
41 $(LINT.c) $$p.c $(LDLIBS) ;\
42 done
43
44 $(TESTDIR)/%: %.ksh
45 $(INS.rename)
46
47 $(TESTDIR):
48 $(INS.dir)
49
50 .KEEP_STATE:
51
52 include $(SRC)/cmd/Makefile.targ