test-autotools-shared/Makefile.am

58 lines
1.7 KiB
Makefile
Raw Normal View History

2015-01-31 20:37:04 +01:00
AM_CFLAGS = # CFLAGS applicable to all executables (products)
2015-06-23 19:17:24 +02:00
AM_CPPFLAGS = -I$(top_srcdir)/src # so that tests also find header files
2020-06-14 22:23:20 +02:00
ACLOCAL_AMFLAGS = -I m4
2015-01-31 20:37:04 +01:00
2020-06-14 22:23:20 +02:00
# libtool library definition
lib_LTLIBRARIES = libtest.la
libtest_la_SOURCES = src/test.h src/test.c
2020-06-14 23:54:05 +02:00
libtest_la_LDFLAGS = -version-info 0:9:0
2015-02-09 22:21:18 +01:00
2020-06-14 22:23:20 +02:00
bin_PROGRAMS = main_executable
2015-06-23 19:17:24 +02:00
#include .c and .h in SOURCES so that both appear in dist
2020-06-14 22:49:42 +02:00
main_executable_SOURCES = src/main.c
2020-06-14 22:23:20 +02:00
main_executable_CFLAGS = $(AM_CFLAGS) $(CODE_COVERAGE_CFLAGS) #--std=c11 # CFLAGS applicable to myexecutable_SOURCES
main_executable_LDADD = libtest.la
main_executable_LDFLAGS = $(CODE_COVERAGE_LDFLAGS)
2015-06-24 22:51:01 +02:00
# myexecutable_CFLAGS = $(CODE_COVERAGE_CFLAGS)
2015-02-09 22:21:18 +01:00
2015-02-06 17:10:11 +01:00
2020-06-14 23:54:05 +02:00
pkgconfig_DATA = libtest.pc
2015-02-06 17:10:11 +01:00
# Tests
# 'check' comes from 'make check'
2015-02-07 21:02:22 +01:00
@VALGRIND_CHECK_RULES@
2015-06-24 22:51:01 +02:00
@CODE_COVERAGE_RULES@
2015-06-24 22:51:01 +02:00
# See all code_coverage_* options in the Makefile or m4/ax_code_coverage.m4
CODE_COVERAGE_IGNORE_PATTERN = tests/*
CODE_COVERAGE_IGNORE_PATTERN += stdio2.h
2020-06-14 22:49:42 +02:00
#TESTS = add.ctaptest
#check_PROGRAMS = add.ctaptest
2015-02-06 20:25:03 +01:00
2020-06-14 22:49:42 +02:00
#add_ctaptest_SOURCES = tests/add.c src/add.c src/add.h
#add_ctaptest_CPPFLAGS = $(AM_CPPFLAGS) # so that tests find the header files
#add_ctaptest_LDFLAGS = $(CODE_COVERAGE_LDFLAGS)
#add_ctaptest_CFLAGS = $(CODE_COVERAGE_CFLAGS)
2015-02-07 21:02:22 +01:00
2015-02-06 17:10:11 +01:00
2015-06-23 21:43:51 +02:00
# See http://www.gnu.org/software/automake/manual/html_node/Use-TAP-with-the-Automake-test-harness.html
# TESTS ending in .ctaptest should produce TAP output
# 1..2
# ok 1 - message
# not ok 2 - message
AUTOMAKE_OPTIONS = parallel-tests
2015-06-23 21:43:51 +02:00
TEST_EXTENSIONS = .ctaptest
CTAPTEST_LOG_DRIVER = env AM_TAP_HAWK='$(AWK)' $(SHELL) $(top_srcdir)/build-aux/tap-driver.sh
# TESTS_ENVIRONMENT = $(VALGRIND)
# CTAPTEST_TESTS_ENVIRONMENT = $(VALGRIND)
# CTAPTEST_LOG_COMPILER = $(VALGRIND)
2015-06-23 21:43:51 +02:00
2015-02-06 17:10:11 +01:00