aboutsummaryrefslogtreecommitdiff
path: root/common/template/Makefile.am
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2012-07-17 15:16:34 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2012-07-17 15:16:34 +0200
commit5aa48fc52202fd95210d8860b66769550732a5d9 (patch)
treec0319bd35076c41a83a8b8a3c67bb8a3db3a182d /common/template/Makefile.am
parent9f2b5f3c24907d603706ff81b459d3f5d3c0882e (diff)
Add support for tests with multiple ODB headers
Diffstat (limited to 'common/template/Makefile.am')
-rw-r--r--common/template/Makefile.am23
1 files changed, 14 insertions, 9 deletions
diff --git a/common/template/Makefile.am b/common/template/Makefile.am
index 4478502..0aa8f83 100644
--- a/common/template/Makefile.am
+++ b/common/template/Makefile.am
@@ -13,15 +13,9 @@ AM_CPPFLAGS += -I'$(builddir)' -I'$(srcdir)'
TESTS=$(top_builddir)/tester
TESTS_ENVIRONMENT=top_builddir=$(top_builddir); export top_builddir;
-m4_ifelse(__value__(odb_options),,,
-
+__ifelse__(__value__(odb_options),,,
# ODB compilation.
#
-driver_SOURCES += test.hxx
-nodist_driver_SOURCES = test-odb.cxx
-BUILT_SOURCES = test-odb.hxx
-CLEANFILES = test-odb.hxx test-odb.ixx test-odb.cxx
-
ODB = @ODB@
ODBFLAGS = @ODBFLAGS@
ODBCPPFLAGS = @ODBCPPFLAGS@
@@ -30,6 +24,17 @@ if HAVE_CXX11
ODBFLAGS += --std c++11
endif
-test-odb.hxx: test.hxx
+nodist_driver_SOURCES =
+BUILT_SOURCES =
+CLEANFILES =
+
+__foreach_w__(__f,__path__(odb_header_stem),
+driver_SOURCES += __f.hxx
+nodist_driver_SOURCES += __f-odb.cxx
+BUILT_SOURCES += __f-odb.hxx
+CLEANFILES += __f-odb.hxx __f-odb.ixx __f-odb.cxx
+
+__f-odb.hxx: __f.hxx
$(ODB) $(AM_CPPFLAGS) $(ODBCPPFLAGS) $(CPPFLAGS) $(ODBFLAGS) __value__(odb_options) $<
-)
+
+))