1490fea6bSYuri Pankov#
2490fea6bSYuri Pankov# This file and its contents are supplied under the terms of the
3490fea6bSYuri Pankov# Common Development and Distribution License ("CDDL"), version 1.0.
4490fea6bSYuri Pankov# You may only use this file in accordance with the terms of version
5490fea6bSYuri Pankov# 1.0 of the CDDL.
6490fea6bSYuri Pankov#
7490fea6bSYuri Pankov# A full copy of the text of the CDDL should have accompanied this
8490fea6bSYuri Pankov# source.  A copy of the CDDL is also available via the Internet at
9490fea6bSYuri Pankov# http://www.illumos.org/license/CDDL.
10490fea6bSYuri Pankov#
11490fea6bSYuri Pankov
12490fea6bSYuri Pankov#
13*16b8cff5SYuri Pankov# Copyright 2018 Nexenta Systems, Inc.
14490fea6bSYuri Pankov#
15490fea6bSYuri Pankov
16490fea6bSYuri Pankovinclude		$(SRC)/Makefile.master
17490fea6bSYuri Pankov
18490fea6bSYuri PankovROOTOPTPKG=	$(ROOT)/opt/libc-tests
19490fea6bSYuri PankovTESTDIR=	$(ROOTOPTPKG)/tests/regex
20490fea6bSYuri PankovDATADIR=	$(TESTDIR)/data
21490fea6bSYuri Pankov
22*16b8cff5SYuri PankovPROG=		testregex
23*16b8cff5SYuri Pankov
24*16b8cff5SYuri PankovSHPROG=		regex_test
25*16b8cff5SYuri Pankov
26*16b8cff5SYuri PankovDATA=		basic.dat basic.out \
27*16b8cff5SYuri Pankov		categorize.dat categorize.out \
28*16b8cff5SYuri Pankov		forcedassoc.dat forcedassoc.out \
29*16b8cff5SYuri Pankov		leftassoc.dat leftassoc.out \
30*16b8cff5SYuri Pankov		nullsubexpr.dat nullsubexpr.out \
31*16b8cff5SYuri Pankov		repetition.dat repetition.out \
32*16b8cff5SYuri Pankov		rightassoc.dat rightassoc.out
33490fea6bSYuri Pankov
34490fea6bSYuri Pankovinclude		$(SRC)/cmd/Makefile.cmd
35490fea6bSYuri Pankov
36*16b8cff5SYuri PankovCERRWARN +=	-_gcc=-Wno-parentheses
37*16b8cff5SYuri PankovCERRWARN +=	-_gcc=-Wno-uninitialized
38*16b8cff5SYuri PankovCERRWARN +=	-_gcc=-Wno-clobbered
39*16b8cff5SYuri Pankov
40490fea6bSYuri PankovCMDS=		$(PROG:%=$(TESTDIR)/%) $(SHPROG:%=$(TESTDIR)/%)
41490fea6bSYuri Pankov$(CMDS):=	FILEMODE=0555
42490fea6bSYuri PankovTESTDATA=	$(DATA:%=$(DATADIR)/%)
43490fea6bSYuri Pankov$(TESTDATA):=	FILEMODE=0444
44490fea6bSYuri Pankov
45490fea6bSYuri Pankov.KEEP_STATE:
46490fea6bSYuri Pankov
47490fea6bSYuri Pankovall:		$(PROG)
48490fea6bSYuri Pankov
49490fea6bSYuri Pankov$(CMDS):	$(TESTDIR)
50490fea6bSYuri Pankov
51490fea6bSYuri Pankov$(TESTDATA):	$(DATADIR)
52490fea6bSYuri Pankov
53490fea6bSYuri Pankovinstall:	all $(CMDS) $(TESTDATA)
54490fea6bSYuri Pankov
55*16b8cff5SYuri Pankovclean lint:
56490fea6bSYuri Pankov
57490fea6bSYuri Pankov$(TESTDIR) $(DATADIR):
58490fea6bSYuri Pankov		$(INS.dir)
59490fea6bSYuri Pankov
60490fea6bSYuri Pankov$(TESTDIR)/%:	%
61490fea6bSYuri Pankov		$(INS.file)
62490fea6bSYuri Pankov
63490fea6bSYuri Pankov$(TESTDIR)/%:	%.sh
64490fea6bSYuri Pankov		$(INS.rename)
65490fea6bSYuri Pankov
66490fea6bSYuri Pankov$(DATADIR)/%:	data/%
67490fea6bSYuri Pankov		$(INS.file)
68490fea6bSYuri Pankov
69490fea6bSYuri Pankovinclude		$(SRC)/cmd/Makefile.targ
70