/
Makefile.am
39 lines (31 loc) · 1.01 KB
/
Makefile.am
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
check_PROGRAMS = test_lib test_ident test_parse test_sem test_simp \
test_elab test_heap
TESTS_ENVIRONMENT = BUILD_DIR=$(top_builddir)
TESTS = $(check_PROGRAMS) run_regr.rb
src = $(top_srcdir)/src
build = $(top_builddir)/src
shared = $(src)/util.c
covdir = $(top_builddir)/coverage
AM_CFLAGS = -I $(src) -I $(build) -DTESTDIR=\"$(top_srcdir)/test\" \
$(CHECK_CFLAGS)
LDADD = -lcheck $(build)/rt/libnvc-rt.a $(build)/libnvc.a $(CHECK_LIBS) \
$(CURSES_LIB)
AM_LDFLAGS = -rdynamic $(COV_LDFLAGS)
test_lib_SOURCES = test_lib.c
test_ident_SOURCES = test_ident.c
test_parse_SOURCES = test_parse.c
test_sem_SOURCES = test_sem.c
test_simp_SOURCES = test_simp.c
clean-local:
-test -d logs && $(RM) -r logs
if ENABLE_COVERAGE
cov-reset:
rm -rf $(covdir)
find $(top_builddir) -name '*.gcda' -exec rm {} \;
lcov --directory $(build) --zerocounters
cov-report:
mkdir -p $(covdir)
lcov --directory $(build) --capture --output-file $(covdir)/nvc.info
genhtml -o $(covdir) $(covdir)/nvc.info
-x-www-browser $(covdir)/index.html
endif