Template replacement engine ported from Shib, added conditional nesting.
[shibboleth/cpp-xmltooling.git] / xmltoolingtest / Makefile.am
1 AUTOMAKE_OPTIONS = foreign
2
3 if BUILD_UNITTEST
4 bin_PROGRAMS = xmltoolingtest
5 xmltoolingtest_CXXFLAGS = $(CXXFLAGS) $(CXXTESTFLAGS)
6 else
7 bin_PROGRAMS = 
8 endif
9
10 if BUILD_XMLSEC
11 xmlsec_sources = \
12     EncryptionTest.h \
13     FilesystemCredentialResolverTest.h \
14     InlineKeyResolverTest.h \
15     SignatureTest.h
16 else
17 xmlsec_sources =
18 endif
19
20 xmltoolingtest_h = \
21     ComplexXMLObjectTest.h \
22     ExceptionTest.h \
23     KeyInfoTest.h \
24     MarshallingTest.h \
25     MemoryStorageServiceTest.h \
26     UnmarshallingTest.h \
27     TemplateEngineTest.h \
28     xmltoolingtest.h \
29     ${xmlsec_sources}
30
31 noinst_HEADERS = \
32     XMLObjectBaseTestCase.h
33
34 nodist_xmltoolingtest_SOURCES = $(xmltoolingtest_h:.h=.cpp)
35
36 CLEANFILES = $(nodist_xmltoolingtest_SOURCES)
37
38 do-cxxtestgen:
39         if test $(HFILE) = "xmltoolingtest.h"; then \
40                 $(CXXTEST) --error-printer --have-eh --have-std --abort-on-fail -o $(CPPFILE) $(HFILE); \
41         else \
42                 $(CXXTEST) --part --have-eh --have-std --abort-on-fail -o $(CPPFILE) $(HFILE); \
43         fi;
44
45 $(nodist_xmltoolingtest_SOURCES): %.cpp: %.h
46         $(MAKE) do-cxxtestgen HFILE=$< CPPFILE=$@
47
48 xmltoolingtest_LDADD = $(top_builddir)/xmltooling/libxmltooling.la
49
50 EXTRA_DIST = xmltoolingtest.vcproj $(xmltoolingtest_h) data