source: src/tests/Makefile.am @ c20fafd

ADTaaron-thesisarm-ehast-experimentalcleanup-dtorsdeferred_resndemanglerenumforall-pointer-decayjacob/cs343-translationjenkins-sandboxnew-astnew-ast-unique-exprno_listpersistent-indexerpthread-emulationqualifiedEnum
Last change on this file since c20fafd was a4248de1, checked in by Thierry Delisle <tdelisle@…>, 6 years ago

New tentative for headers using wildcard characters in rules

  • Property mode set to 100644
File size: 4.4 KB
RevLine 
[ef7d253]1######################## -*- Mode: Makefile-Automake -*- ######################
2##
3## Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
4##
5## The contents of this file are covered under the licence agreement in the
6## file "LICENCE" distributed with Cforall.
7##
8## Makefile.am --
9##
10## Author           : Peter A. Buhr
11## Created On       : Sun May 31 09:08:15 2015
12## Last Modified By : Peter A. Buhr
[2248dc7]13## Last Modified On : Wed Jun  6 16:42:20 2018
14## Update Count     : 49
[ef7d253]15###############################################################################
16
[f85bc15]17
[cc640aad]18debug=yes
19
[5cacf74]20quick_test=avl_test operators numericConstants expression enum array typeof cast raii/dtor-early-exit raii/init_once attributes
[be65cca]21
22if BUILD_CONCURRENCY
[0ad0c55]23concurrent=
[be65cca]24else
[0ad0c55]25concurrent='-Econcurrent'
[be65cca]26endif
27
[f85bc15]28TEST_PY = python ${srcdir}/test.py
29
[ef7d253]30# applies to both programs
[b8f6002]31AM_CFLAGS = $(if $(test), 2> $(test), ) \
32        -XCFA \
33        -t \
34        -B${abs_top_builddir}/src/driver \
35        -g \
36        -Wall \
37        -Wno-unused-function \
38        -quiet @CFA_FLAGS@ \
39        -I. \
40        -DIN_DIR="${srcdir}/.in/" \
41        -L${abs_top_builddir}/src/libcfa \
42        -I${abs_top_srcdir}/src/libcfa \
43        -I${abs_top_srcdir}/src/libcfa/containers \
44        -I${abs_top_srcdir}/src/libcfa/concurrency \
45        -I${abs_top_srcdir}/src/libcfa/stdhdr
[7c03d6d]46
[b5f9829]47if !BUILD_DEBUG
[b8f6002]48AM_CFLAGS += -nodebug
[b5f9829]49else
50if !BUILD_RELEASE
[b8f6002]51AM_CFLAGS += -debug
[b5f9829]52else
[b8f6002]53AM_CFLAGS += ${DEBUG_FLAGS}
[b5f9829]54endif
55endif
56
[857638d]57CC = ${abs_top_builddir}/src/driver/cfa
[ef7d253]58
[927e9ce]59.PHONY : list
[293377c]60EXTRA_PROGRAMS = fstream_test avl_test # build but do not install
[927e9ce]61
[e68b3a8]62fstream_test_SOURCES = fstream_test.c
[44f44617]63
[e68b3a8]64avl_test_SOURCES = avltree/avl_test.c avltree/avl0.c avltree/avl1.c avltree/avl2.c avltree/avl3.c avltree/avl4.c avltree/avl-private.c
[a0dcd2e]65
[927e9ce]66all-local :
[f85bc15]67        @+${TEST_PY} --debug=${debug} ${concurrent} ${quick_test}
[df42128]68
69all-tests :
[f85bc15]70        @+${TEST_PY} --all --debug=${debug} ${concurrent}               # '@' => do not echo command (SILENT), '+' => allows recursive make from within python program
[927e9ce]71
72clean-local :
[a6dd5b0]73        rm -f ${EXTRA_PROGRAMS}
[927e9ce]74
75list :
[f85bc15]76        @+${TEST_PY} --list ${concurrent}
[927e9ce]77
[026a0f5]78concurrency :
[f85bc15]79        @+${TEST_PY} --debug=${debug} -Iconcurrent
[026a0f5]80
[4f18de3]81# SKULLDUGGERY like libcfa/Makefile.am prevent extensionless headers from being generated
[a4248de1]82# however, here it is more complicated because it must match the dependencies based on how
83# they are generated by gcc
[4f18de3]84headers = $(shell find $(top_srcdir)/src/libcfa -type f ! -name "*.*")
[a4248de1]85headers_real = $(shell realpath --relative-to=$(top_srcdir)/src/libcfa $(headers))
86headers_deps = $(addprefix %/, $(headers_real))
[4f18de3]87$(headers_deps) :
88        echo "Dummy rule, should never be called"
89
[a4248de1]90# %/stdlib:
91#       echo "Dummy rule, should never be called"
92
[4f18de3]93# implicit rule so not all test require a rule
[b8f6002]94% : %.c $(CC)
[a4248de1]95        echo $(headers_deps)
[e68b3a8]96        $(COMPILE) $(abspath ${<}) -o ${@}
[8f8af30]97
[b8f6002]98declarationSpecifier: declarationSpecifier.c $(CC)
[e68b3a8]99        $(COMPILE) -CFA -XCFA -p $(abspath ${<}) -o ${@}
[950f7a7]100
[b8f6002]101gccExtensions : gccExtensions.c $(CC)
[e68b3a8]102        $(COMPILE) -CFA -XCFA -p $(abspath ${<}) -o ${@}
[d9b499c]103
[b8f6002]104extension : extension.c $(CC)
[e68b3a8]105        $(COMPILE) -CFA -XCFA -p $(abspath ${<}) -o ${@}
[d9b499c]106
[b8f6002]107attributes : attributes.c $(CC)
[e68b3a8]108        $(COMPILE) -CFA -XCFA -p $(abspath ${<}) -o ${@}
[481115f]109
[b8f6002]110functions: functions.c $(CC)
[e68b3a8]111        $(COMPILE) -CFA -XCFA -p $(abspath ${<}) -o ${@}
[c0aa336]112
[b8f6002]113KRfunctions : KRfunctions.c $(CC)
[e68b3a8]114        $(COMPILE) -CFA -XCFA -p $(abspath ${<}) -o ${@}
[3a5131ed]115
[b8f6002]116sched-ext-parse : sched-ext-parse.c $(CC)
[e68b3a8]117        $(COMPILE) -CFA -XCFA -p $(abspath ${<}) -o ${@}
[a843067]118
[b8f6002]119gmp : gmp.c $(CC)
[e68b3a8]120        $(COMPILE) -lgmp $(abspath ${<}) -o ${@}
[4c8f86b3]121
[b8f6002]122completeTypeError : completeTypeError.c $(CC)
[e68b3a8]123        $(COMPILE) -DERR1 $(abspath ${<}) -o ${@}
[486341f]124
[b8f6002]125typedefRedef-ERR1: typedefRedef.c $(CC)
[e68b3a8]126        $(COMPILE) -DERR1 $(abspath ${<}) -o ${@}
[b93a3de]127
[b8f6002]128alloc-ERROR: alloc.c $(CC)
[e68b3a8]129        $(COMPILE) -DERR1 $(abspath ${<}) -o ${@}
[70529dc]130
[b8f6002]131fallthrough-ERROR: fallthrough.c $(CC)
[e68b3a8]132        $(COMPILE) -DERR1 $(abspath ${<}) -o ${@}
[e2c70ab]133
[b8f6002]134nested-types-ERR1: nested-types.c $(CC)
[e68b3a8]135        $(COMPILE) -DERR1 $(abspath ${<}) -o ${@}
[49e1275]136
[b8f6002]137nested-types-ERR2: nested-types.c $(CC)
[e68b3a8]138        $(COMPILE) -DERR2 $(abspath ${<}) -o ${@}
[49e1275]139
[80e8582]140# Constructor/destructor tests
[b8f6002]141raii/dtor-early-exit-ERR1: raii/dtor-early-exit.c $(CC)
[e68b3a8]142        $(COMPILE) -DERR1 $(abspath ${<}) -o ${@}
[cdbfab0]143
[b8f6002]144raii/dtor-early-exit-ERR2: raii/dtor-early-exit.c $(CC)
[e68b3a8]145        $(COMPILE) -DERR2 $(abspath ${<}) -o ${@}
[80e8582]146
[b8f6002]147raii/memberCtors-ERR1: raii/memberCtors.c $(CC)
[e68b3a8]148        $(COMPILE) -DERR1 $(abspath ${<}) -o ${@}
[80e8582]149
[b8f6002]150raii/ctor-autogen-ERR1: raii/ctor-autogen.c $(CC)
[e68b3a8]151        $(COMPILE) -DERR1 $(abspath ${<}) -o ${@}
[80e8582]152
[1feb535f]153# Warnings
[b8f6002]154warnings/self-assignment: warnings/self-assignment.c $(CC)
[e68b3a8]155        $(COMPILE) $(abspath ${<}) 2> ${@} -fsyntax-only
[13073be]156
157#builtins
[b8f6002]158builtins/sync: builtins/sync.c $(CC)
[e68b3a8]159        $(COMPILE) $(abspath ${<}) 2> ${@} -fsyntax-only
Note: See TracBrowser for help on using the repository browser.