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# Copyright 2019, Richard Lowe. 13 14include $(SRC)/cmd/Makefile.cmd 15include $(SRC)/test/Makefile.com 16 17PROG = test-parser 18 19DATAFILES= mapfile.addrsize.good \ 20 mapfile.addrsize.mult \ 21 mapfile.addrsize.substring \ 22 mapfile.addrsize.superstring \ 23 mapfile.addrsize.wrong \ 24 mapfile.sizemult.good \ 25 mapfile.sizemult.noterm \ 26 mapfile.sizemult.overflow \ 27 mapfile.sizemult.twobegin \ 28 mapfile.sizemult.wrong \ 29 object.c 30 31ROOTOPTPKG = $(ROOT)/opt/elf-tests 32TESTDIR = $(ROOTOPTPKG)/tests/mapfiles/parser 33 34CMDS = $(PROG:%=$(TESTDIR)/%) 35$(CMDS) := FILEMODE = 0555 36 37DATA = $(DATAFILES:%=$(TESTDIR)/%) 38$(DATA) := FILEMODE = 0444 39 40all: $(PROG) 41 42install: all $(CMDS) $(DATA) 43 44clobber: clean 45 -$(RM) $(PROG) 46 47clean: 48 -$(RM) $(CLEANFILES) 49 50$(CMDS): $(TESTDIR) $(PROG) 51 52$(TESTDIR): 53 $(INS.dir) 54 55$(TESTDIR)/%: % 56 $(INS.file) 57