xref: /illumos-gate/usr/src/test/util-tests/tests/head/Makefile (revision 8226594fdd4479be135127f43632f1f995074654)
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 2020 Oxide Computer Company
14#
15
16include $(SRC)/cmd/Makefile.cmd
17include $(SRC)/test/Makefile.com
18
19ROOTOPTPKG = $(ROOT)/opt/util-tests/tests/head
20PROG = head_test
21DATAFILES =			\
22	5221.in			\
23	5221.out		\
24	multi.1.out		\
25	multi.4.out		\
26	rings.1.out		\
27	rings.2.out		\
28	rings.3.out		\
29	rings.5.out		\
30	rings.in		\
31	stdin-nul.1.out		\
32	stdin-nul.2.out		\
33	stdin-nul.3.out		\
34	stdin.1.out		\
35	stdin.11.out		\
36	stdin.2.out		\
37	stdin.3.out		\
38	stdin.5.out		\
39	stdin.multi.out		\
40	stdin.nonewline.out
41
42
43ROOTPROG = $(PROG:%=$(ROOTOPTPKG)/%)
44ROOTDATA = $(DATAFILES:%=$(ROOTOPTPKG)/%)
45
46$(ROOTDATA) := FILEMODE = 0444
47
48all:
49
50install: $(ROOTPROG) $(ROOTDATA)
51
52lint:
53
54clobber: clean
55
56clean:
57
58$(CMDS): $(TESTDIR)
59
60$(ROOTOPTPKG):
61	$(INS.dir)
62
63$(ROOTOPTPKG)/%: %.ksh $(ROOTOPTPKG)
64	$(INS.rename)
65
66$(ROOTOPTPKG)/%: % $(ROOTOPTPKG)
67	$(INS.file)
68