David Reiss | 351e22b | 2010-08-31 16:51:19 +0000 | [diff] [blame] | 1 | # |
| 2 | # Licensed to the Apache Software Foundation (ASF) under one |
| 3 | # or more contributor license agreements. See the NOTICE file |
| 4 | # distributed with this work for additional information |
| 5 | # regarding copyright ownership. The ASF licenses this file |
| 6 | # to you under the Apache License, Version 2.0 (the |
| 7 | # "License"); you may not use this file except in compliance |
| 8 | # with the License. You may obtain a copy of the License at |
| 9 | # |
| 10 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 11 | # |
| 12 | # Unless required by applicable law or agreed to in writing, |
| 13 | # software distributed under the License is distributed on an |
| 14 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| 15 | # KIND, either express or implied. See the License for the |
| 16 | # specific language governing permissions and limitations |
| 17 | # under the License. |
| 18 | # |
| 19 | |
| 20 | noinst_LTLIBRARIES = libtestgencpp.la |
| 21 | nodist_libtestgencpp_la_SOURCES = \ |
| 22 | gen-cpp/DebugProtoTest_types.cpp \ |
| 23 | gen-cpp/OptionalRequiredTest_types.cpp \ |
| 24 | gen-cpp/DebugProtoTest_types.cpp \ |
| 25 | gen-cpp/ThriftTest_types.cpp \ |
| 26 | gen-cpp/DebugProtoTest_types.h \ |
| 27 | gen-cpp/OptionalRequiredTest_types.h \ |
| 28 | gen-cpp/ThriftTest_types.h \ |
| 29 | ThriftTest_extras.cpp \ |
| 30 | DebugProtoTest_extras.cpp |
| 31 | |
| 32 | ThriftTest_extras.o: gen-cpp/ThriftTest_types.h |
| 33 | DebugProtoTest_extras.o: gen-cpp/DebugProtoTest_types.h |
| 34 | |
| 35 | libtestgencpp_la_LIBADD = $(top_builddir)/lib/cpp/libthrift.la |
| 36 | |
| 37 | noinst_PROGRAMS = Benchmark |
| 38 | |
| 39 | Benchmark_SOURCES = \ |
| 40 | Benchmark.cpp |
| 41 | |
| 42 | Benchmark_LDADD = libtestgencpp.la |
| 43 | |
| 44 | check_PROGRAMS = \ |
| 45 | TFDTransportTest \ |
| 46 | TPipedTransportTest \ |
| 47 | DebugProtoTest \ |
| 48 | JSONProtoTest \ |
| 49 | OptionalRequiredTest \ |
| 50 | AllProtocolsTest \ |
| 51 | UnitTests |
| 52 | |
| 53 | TESTS = \ |
| 54 | $(check_PROGRAMS) |
| 55 | |
| 56 | UnitTests_SOURCES = \ |
| 57 | UnitTestMain.cpp \ |
| 58 | TMemoryBufferTest.cpp \ |
| 59 | TBufferBaseTest.cpp |
| 60 | |
Roger Meier | 8a441a4 | 2010-10-04 21:13:36 +0000 | [diff] [blame^] | 61 | UnitTests_LDADD = $(BOOST_LDFLAGS) libtestgencpp.la -lboost_unit_test_framework |
David Reiss | 351e22b | 2010-08-31 16:51:19 +0000 | [diff] [blame] | 62 | |
| 63 | # |
| 64 | # TFDTransportTest |
| 65 | # |
| 66 | TFDTransportTest_SOURCES = \ |
| 67 | TFDTransportTest.cpp |
| 68 | |
| 69 | TFDTransportTest_LDADD = \ |
| 70 | $(top_builddir)/lib/cpp/libthrift.la |
| 71 | |
| 72 | |
| 73 | # |
| 74 | # TPipedTransportTest |
| 75 | # |
| 76 | TPipedTransportTest_SOURCES = \ |
| 77 | TPipedTransportTest.cpp |
| 78 | |
| 79 | TPipedTransportTest_LDADD = \ |
| 80 | $(top_builddir)/lib/cpp/libthrift.la |
| 81 | |
| 82 | # |
| 83 | # AllProtocolsTest |
| 84 | # |
| 85 | AllProtocolsTest_SOURCES = \ |
| 86 | AllProtocolTests.cpp \ |
| 87 | AllProtocolTests.tcc \ |
| 88 | GenericHelpers.h |
| 89 | |
| 90 | AllProtocolsTest_LDADD = libtestgencpp.la |
| 91 | |
| 92 | # |
| 93 | # DebugProtoTest |
| 94 | # |
| 95 | DebugProtoTest_SOURCES = \ |
| 96 | DebugProtoTest.cpp |
| 97 | |
| 98 | DebugProtoTest_LDADD = libtestgencpp.la |
| 99 | |
| 100 | |
| 101 | # |
| 102 | # JSONProtoTest |
| 103 | # |
| 104 | JSONProtoTest_SOURCES = \ |
| 105 | JSONProtoTest.cpp |
| 106 | |
| 107 | JSONProtoTest_LDADD = libtestgencpp.la |
| 108 | |
| 109 | # |
| 110 | # OptionalRequiredTest |
| 111 | # |
| 112 | OptionalRequiredTest_SOURCES = \ |
| 113 | OptionalRequiredTest.cpp |
| 114 | |
| 115 | OptionalRequiredTest_LDADD = libtestgencpp.la |
| 116 | |
| 117 | |
| 118 | # |
| 119 | # Common thrift code generation rules |
| 120 | # |
| 121 | THRIFT = $(top_builddir)/compiler/cpp/thrift |
| 122 | |
| 123 | gen-cpp/DebugProtoTest_types.cpp gen-cpp/DebugProtoTest_types.h: $(top_srcdir)/test/DebugProtoTest.thrift |
| 124 | $(THRIFT) --gen cpp:dense $< |
| 125 | |
| 126 | gen-cpp/OptionalRequiredTest_types.cpp gen-cpp/OptionalRequiredTest_types.h: $(top_srcdir)/test/OptionalRequiredTest.thrift |
| 127 | $(THRIFT) --gen cpp:dense $< |
| 128 | |
| 129 | gen-cpp/Service.cpp gen-cpp/StressTest_types.cpp: $(top_srcdir)/test/StressTest.thrift |
| 130 | $(THRIFT) --gen cpp:dense $< |
| 131 | |
| 132 | gen-cpp/SecondService.cpp gen-cpp/ThriftTest_constants.cpp gen-cpp/ThriftTest.cpp gen-cpp/ThriftTest_types.cpp gen-cpp/ThriftTest_types.h: $(top_srcdir)/test/ThriftTest.thrift |
| 133 | $(THRIFT) --gen cpp:dense $< |
| 134 | |
| 135 | INCLUDES = \ |
| 136 | -I$(top_srcdir)/lib/cpp/src |
| 137 | |
| 138 | AM_CPPFLAGS = $(BOOST_CPPFLAGS) |
| 139 | |
| 140 | clean-local: |
| 141 | $(RM) -r gen-cpp |
| 142 | |
| 143 | EXTRA_DIST = \ |
| 144 | ZlibTest.cpp \ |
| 145 | DenseProtoTest.cpp \ |
| 146 | ThriftTest_extras.cpp \ |
| 147 | DebugProtoTest_extras.cpp |