Gavin McDonald | 0b75e1a | 2010-10-28 02:12:01 +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 | SUBDIRS = |
| 21 | |
| 22 | if WITH_PYTHON |
| 23 | SUBDIRS += py |
| 24 | endif |
| 25 | |
| 26 | if WITH_RUBY |
| 27 | SUBDIRS += rb |
| 28 | endif |
| 29 | |
| 30 | noinst_LTLIBRARIES = libtestgencpp.la |
| 31 | libtestgencpp_la_SOURCES = \ |
| 32 | gen-cpp/DebugProtoTest_types.cpp \ |
| 33 | gen-cpp/OptionalRequiredTest_types.cpp \ |
| 34 | gen-cpp/DebugProtoTest_types.cpp \ |
| 35 | gen-cpp/ThriftTest_types.cpp \ |
| 36 | gen-cpp/DebugProtoTest_types.h \ |
| 37 | gen-cpp/OptionalRequiredTest_types.h \ |
| 38 | gen-cpp/ThriftTest_types.h \ |
| 39 | ThriftTest_extras.cpp \ |
| 40 | DebugProtoTest_extras.cpp |
| 41 | |
| 42 | ThriftTest_extras.o: gen-cpp/ThriftTest_types.h |
| 43 | DebugProtoTest_extras.o: gen-cpp/DebugProtoTest_types.h |
| 44 | |
| 45 | libtestgencpp_la_LIBADD = $(top_builddir)/lib/cpp/libthrift.la |
| 46 | |
| 47 | noinst_PROGRAMS = Benchmark |
| 48 | |
| 49 | Benchmark_SOURCES = \ |
| 50 | Benchmark.cpp |
| 51 | |
| 52 | Benchmark_LDADD = libtestgencpp.la |
| 53 | |
| 54 | check_PROGRAMS = \ |
| 55 | TFDTransportTest \ |
| 56 | TPipedTransportTest \ |
| 57 | DebugProtoTest \ |
| 58 | JSONProtoTest \ |
| 59 | OptionalRequiredTest \ |
| 60 | AllProtocolsTest \ |
| 61 | UnitTests |
| 62 | |
| 63 | TESTS = \ |
| 64 | $(check_PROGRAMS) |
| 65 | |
| 66 | UnitTests_SOURCES = \ |
| 67 | UnitTestMain.cpp \ |
| 68 | TMemoryBufferTest.cpp \ |
| 69 | TBufferBaseTest.cpp |
| 70 | |
| 71 | UnitTests_LDADD = libtestgencpp.la |
| 72 | |
| 73 | # |
| 74 | # TFDTransportTest |
| 75 | # |
| 76 | TFDTransportTest_SOURCES = \ |
| 77 | TFDTransportTest.cpp |
| 78 | |
| 79 | TFDTransportTest_LDADD = \ |
| 80 | $(top_builddir)/lib/cpp/libthrift.la |
| 81 | |
| 82 | |
| 83 | # |
| 84 | # TPipedTransportTest |
| 85 | # |
| 86 | TPipedTransportTest_SOURCES = \ |
| 87 | TPipedTransportTest.cpp |
| 88 | |
| 89 | TPipedTransportTest_LDADD = \ |
| 90 | $(top_builddir)/lib/cpp/libthrift.la |
| 91 | |
| 92 | # |
| 93 | # AllProtocolsTest |
| 94 | # |
| 95 | AllProtocolsTest_SOURCES = \ |
| 96 | AllProtocolTests.cpp \ |
| 97 | AllProtocolTests.tcc \ |
| 98 | GenericHelpers.h |
| 99 | |
| 100 | AllProtocolsTest_LDADD = libtestgencpp.la |
| 101 | |
| 102 | # |
| 103 | # DebugProtoTest |
| 104 | # |
| 105 | DebugProtoTest_SOURCES = \ |
| 106 | DebugProtoTest.cpp |
| 107 | |
| 108 | DebugProtoTest_LDADD = libtestgencpp.la |
| 109 | |
| 110 | |
| 111 | # |
| 112 | # JSONProtoTest |
| 113 | # |
| 114 | JSONProtoTest_SOURCES = \ |
| 115 | JSONProtoTest.cpp |
| 116 | |
| 117 | JSONProtoTest_LDADD = libtestgencpp.la |
| 118 | |
| 119 | # |
| 120 | # OptionalRequiredTest |
| 121 | # |
| 122 | OptionalRequiredTest_SOURCES = \ |
| 123 | OptionalRequiredTest.cpp |
| 124 | |
| 125 | OptionalRequiredTest_LDADD = libtestgencpp.la |
| 126 | |
| 127 | |
| 128 | # |
| 129 | # Common thrift code generation rules |
| 130 | # |
| 131 | THRIFT = $(top_builddir)/compiler/cpp/thrift |
| 132 | |
| 133 | gen-cpp/DebugProtoTest_types.cpp gen-cpp/DebugProtoTest_types.h: DebugProtoTest.thrift |
| 134 | $(THRIFT) --gen cpp:dense $< |
| 135 | |
| 136 | gen-cpp/OptionalRequiredTest_types.cpp gen-cpp/OptionalRequiredTest_types.h: OptionalRequiredTest.thrift |
| 137 | $(THRIFT) --gen cpp:dense $< |
| 138 | |
| 139 | gen-cpp/Service.cpp gen-cpp/StressTest_types.cpp: StressTest.thrift |
| 140 | $(THRIFT) --gen cpp:dense $< |
| 141 | |
| 142 | gen-cpp/SecondService.cpp gen-cpp/ThriftTest_constants.cpp gen-cpp/ThriftTest.cpp gen-cpp/ThriftTest_types.cpp gen-cpp/ThriftTest_types.h: ThriftTest.thrift |
| 143 | $(THRIFT) --gen cpp:dense $< |
| 144 | |
| 145 | INCLUDES = \ |
| 146 | -I$(top_srcdir)/lib/cpp/src |
| 147 | |
| 148 | AM_CPPFLAGS = $(BOOST_CPPFLAGS) |
| 149 | |
| 150 | clean-local: |
| 151 | $(RM) -r gen-cpp |
| 152 | |
| 153 | EXTRA_DIST = \ |
| 154 | cpp \ |
| 155 | threads \ |
| 156 | csharp \ |
| 157 | py \ |
| 158 | rb \ |
| 159 | perl \ |
| 160 | php \ |
| 161 | erl \ |
| 162 | hs \ |
| 163 | ocaml \ |
| 164 | AnnotationTest.thrift \ |
| 165 | BrokenConstants.thrift \ |
| 166 | ConstantsDemo.thrift \ |
| 167 | DebugProtoTest.thrift \ |
| 168 | DenseLinkingTest.thrift \ |
| 169 | DocTest.thrift \ |
| 170 | JavaBeansTest.thrift \ |
| 171 | ManyTypedefs.thrift \ |
| 172 | OptionalRequiredTest.thrift \ |
| 173 | SmallTest.thrift \ |
| 174 | StressTest.thrift \ |
| 175 | ThriftTest.thrift \ |
| 176 | ZlibTest.cpp \ |
| 177 | DenseProtoTest.cpp \ |
| 178 | FastbinaryTest.py |