blob: 023165adb35333b96fb75d4838b2541efe6d82d3 [file] [log] [blame]
Roger Meierc2cc61a2010-11-30 19:53:29 +00001#
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#
Kevin Wojniaka3925662019-07-01 11:07:45 -070019AUTOMAKE_OPTIONS = subdir-objects serial-tests nostdinc
Roger Meier81a1f992014-10-22 14:09:43 +020020
Roger Meier213a6642010-10-27 12:30:11 +000021SUBDIRS =
22
Nobuaki Sukegawaef0a8fa2015-05-10 20:21:17 +090023BUILT_SOURCES = \
Jens Geyer54f392b2015-08-05 21:45:10 +020024 gen-c_glib/t_test_container_test_types.c \
25 gen-c_glib/t_test_container_test_types.h \
Nobuaki Sukegawaef0a8fa2015-05-10 20:21:17 +090026 gen-c_glib/t_test_debug_proto_test_types.h \
27 gen-c_glib/t_test_empty_service.h \
28 gen-c_glib/t_test_inherited.h \
29 gen-c_glib/t_test_optional_required_test_types.h \
30 gen-c_glib/t_test_reverse_order_service.h \
31 gen-c_glib/t_test_second_service.h \
32 gen-c_glib/t_test_service_for_exception_with_a_map.h \
Jens Geyer54f392b2015-08-05 21:45:10 +020033 gen-c_glib/t_test_container_service.c \
34 gen-c_glib/t_test_container_service.h \
Nobuaki Sukegawaef0a8fa2015-05-10 20:21:17 +090035 gen-c_glib/t_test_srv.h \
36 gen-c_glib/t_test_thrift_test.h \
37 gen-c_glib/t_test_thrift_test_types.h
38
Kevin Wojniaka3925662019-07-01 11:07:45 -070039AM_CPPFLAGS = -I../src -I./gen-c_glib -I$(top_builddir)/lib/c_glib/src/thrift
James E. King, III36628a22017-02-13 15:25:41 -050040AM_CFLAGS = -g -Wall -Wextra -pedantic $(GLIB_CFLAGS) $(GOBJECT_CFLAGS) $(OPENSSL_INCLUDES) \
Simon Southdb3646f2015-08-01 12:18:12 +000041 @GCOV_CFLAGS@
42AM_CXXFLAGS = $(AM_CFLAGS)
zeshuai007037753e2020-11-30 11:16:10 +080043AM_LDFLAGS = $(GLIB_LIBS) $(GOBJECT_LIBS) $(OPENSSL_LIBS) $(ZLIB_LIBS) @GCOV_LDFLAGS@
Roger Meier213a6642010-10-27 12:30:11 +000044
Roger Meier213a6642010-10-27 12:30:11 +000045check_PROGRAMS = \
Nobuaki Sukegawa362a5ed2015-12-01 22:17:24 +090046 testserialization \
Roger Meier909f1862014-07-24 23:52:14 +020047 testapplicationexception \
Jens Geyer54f392b2015-08-05 21:45:10 +020048 testcontainertest \
Roger Meier213a6642010-10-27 12:30:11 +000049 testtransportsocket \
James E. King, III36628a22017-02-13 15:25:41 -050050 testtransportsslsocket \
Roger Meierc1010922010-11-26 10:17:48 +000051 testbinaryprotocol \
Chandler May6dde90b2016-01-10 06:01:10 +000052 testcompactprotocol \
Roger Meier213a6642010-10-27 12:30:11 +000053 testbufferedtransport \
54 testframedtransport \
zeshuai007037753e2020-11-30 11:16:10 +080055 testzlibtransport \
Simon Southe71f20c2016-02-11 06:52:37 -050056 testfdtransport \
Roger Meier213a6642010-10-27 12:30:11 +000057 testmemorybuffer \
58 teststruct \
59 testsimpleserver \
60 testdebugproto \
61 testoptionalrequired \
zeshuai007c80b8bb2020-07-23 09:43:41 +080062 testthrifttest \
63 testthriftbinaryreadcheck \
64 testthriftcompactreadcheck \
65 testthriftbufferedreadcheck \
66 testthriftfdreadcheck \
67 testthriftframedreadcheck \
68 testthriftmemorybufferreadcheck
Roger Meier213a6642010-10-27 12:30:11 +000069
70if WITH_CPP
Nobuaki Sukegawaef0a8fa2015-05-10 20:21:17 +090071 BUILT_SOURCES += gen-cpp/ThriftTest_types.cpp
zeshuai007037753e2020-11-30 11:16:10 +080072 check_PROGRAMS += testthrifttestclient \
73 testthrifttestzlibclient
Roger Meier213a6642010-10-27 12:30:11 +000074endif
75
Nobuaki Sukegawa362a5ed2015-12-01 22:17:24 +090076testserialization_SOURCES = testserialization.c
77testserialization_LDADD = \
78 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_protocol.o \
79 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
zeshuai007c80b8bb2020-07-23 09:43:41 +080080 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o \
Nobuaki Sukegawa362a5ed2015-12-01 22:17:24 +090081 libtestgenc.la
82
Roger Meier909f1862014-07-24 23:52:14 +020083testapplicationexception_SOURCES = testapplicationexception.c
84testapplicationexception_LDADD = \
Jens Geyer86777192015-07-25 15:59:46 +020085 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_application_exception.o \
86 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_protocol.o \
87 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_struct.o \
zeshuai007c80b8bb2020-07-23 09:43:41 +080088 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
89 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
Roger Meier909f1862014-07-24 23:52:14 +020090
Jens Geyer54f392b2015-08-05 21:45:10 +020091testcontainertest_SOURCES = testcontainertest.c
92testcontainertest_LDADD = \
93 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_struct.o \
94 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_protocol.o \
95 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
96 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport_factory.o \
97 $(top_builddir)/lib/c_glib/src/thrift/c_glib/processor/libthrift_c_glib_la-thrift_processor.o \
98 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_protocol_factory.o \
99 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_binary_protocol.o \
100 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_binary_protocol_factory.o \
101 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_socket.o \
102 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_transport.o \
103 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_socket.o \
104 $(top_builddir)/lib/c_glib/src/thrift/c_glib/server/libthrift_c_glib_la-thrift_server.o \
zeshuai007c80b8bb2020-07-23 09:43:41 +0800105 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o \
106 libtestgenc.la
Jens Geyer54f392b2015-08-05 21:45:10 +0200107
Roger Meier213a6642010-10-27 12:30:11 +0000108testtransportsocket_SOURCES = testtransportsocket.c
109testtransportsocket_LDADD = \
Jens Geyer86777192015-07-25 15:59:46 +0200110 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
111 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_buffered_transport.o \
112 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_transport.o \
zeshuai007c80b8bb2020-07-23 09:43:41 +0800113 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_socket.o \
114 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
Roger Meier213a6642010-10-27 12:30:11 +0000115
James E. King, III36628a22017-02-13 15:25:41 -0500116
117testtransportsslsocket_SOURCES = testtransportsslsocket.c
118testtransportsslsocket_LDADD = \
119 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
120 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_socket.o \
121 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_buffered_transport.o \
122 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_transport.o \
zeshuai007c80b8bb2020-07-23 09:43:41 +0800123 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_socket.o \
124 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
James E. King, III36628a22017-02-13 15:25:41 -0500125
126
Roger Meierc1010922010-11-26 10:17:48 +0000127testbinaryprotocol_SOURCES = testbinaryprotocol.c
128testbinaryprotocol_LDADD = \
Jens Geyer86777192015-07-25 15:59:46 +0200129 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_protocol.o \
130 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
Chandler May1ccd81b2016-02-11 08:25:25 -0500131 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_framed_transport.o \
Jens Geyer86777192015-07-25 15:59:46 +0200132 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_socket.o \
133 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_transport.o \
zeshuai007c80b8bb2020-07-23 09:43:41 +0800134 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_socket.o \
135 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
Roger Meier213a6642010-10-27 12:30:11 +0000136
Chandler May6dde90b2016-01-10 06:01:10 +0000137testcompactprotocol_SOURCES = testcompactprotocol.c
138testcompactprotocol_LDADD = \
139 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_protocol.o \
140 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
Chandler May1ccd81b2016-02-11 08:25:25 -0500141 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_framed_transport.o \
Chandler May6dde90b2016-01-10 06:01:10 +0000142 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_socket.o \
143 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_transport.o \
zeshuai007c80b8bb2020-07-23 09:43:41 +0800144 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_socket.o \
145 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
Chandler May6dde90b2016-01-10 06:01:10 +0000146
Roger Meier213a6642010-10-27 12:30:11 +0000147testbufferedtransport_SOURCES = testbufferedtransport.c
148testbufferedtransport_LDADD = \
Jens Geyer86777192015-07-25 15:59:46 +0200149 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
150 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_socket.o \
151 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_transport.o \
zeshuai007c80b8bb2020-07-23 09:43:41 +0800152 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_socket.o \
153 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
Roger Meier213a6642010-10-27 12:30:11 +0000154
155testframedtransport_SOURCES = testframedtransport.c
156testframedtransport_LDADD = \
Jens Geyer86777192015-07-25 15:59:46 +0200157 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
158 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_socket.o \
159 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_transport.o \
zeshuai007c80b8bb2020-07-23 09:43:41 +0800160 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_socket.o \
161 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
Roger Meier213a6642010-10-27 12:30:11 +0000162
zeshuai007037753e2020-11-30 11:16:10 +0800163testzlibtransport_SOURCES = testzlibtransport.c
164testzlibtransport_LDADD = \
165 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
166 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_socket.o \
167 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_transport.o \
168 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_socket.o \
169 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
170
Simon Southe71f20c2016-02-11 06:52:37 -0500171testfdtransport_SOURCES = testfdtransport.c
172testfdtransport_LDADD = \
173 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
zeshuai007c80b8bb2020-07-23 09:43:41 +0800174 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_fd_transport.o \
175 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
Simon Southe71f20c2016-02-11 06:52:37 -0500176
Roger Meier213a6642010-10-27 12:30:11 +0000177testmemorybuffer_SOURCES = testmemorybuffer.c
178testmemorybuffer_LDADD = \
zeshuai007c80b8bb2020-07-23 09:43:41 +0800179 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
180 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
Roger Meier213a6642010-10-27 12:30:11 +0000181
182teststruct_SOURCES = teststruct.c
183teststruct_LDADD = \
Jens Geyer86777192015-07-25 15:59:46 +0200184 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_protocol.o \
zeshuai007c80b8bb2020-07-23 09:43:41 +0800185 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
186 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
Roger Meier213a6642010-10-27 12:30:11 +0000187
188testsimpleserver_SOURCES = testsimpleserver.c
189testsimpleserver_LDADD = \
Jens Geyer86777192015-07-25 15:59:46 +0200190 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_protocol.o \
191 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
192 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport_factory.o \
193 $(top_builddir)/lib/c_glib/src/thrift/c_glib/processor/libthrift_c_glib_la-thrift_processor.o \
194 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_protocol_factory.o \
195 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_binary_protocol.o \
196 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_binary_protocol_factory.o \
197 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_socket.o \
198 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_transport.o \
199 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_socket.o \
zeshuai007c80b8bb2020-07-23 09:43:41 +0800200 $(top_builddir)/lib/c_glib/src/thrift/c_glib/server/libthrift_c_glib_la-thrift_server.o \
201 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
Roger Meier213a6642010-10-27 12:30:11 +0000202
203testdebugproto_SOURCES = testdebugproto.c
204testdebugproto_LDADD = libtestgenc.la
205
206testoptionalrequired_SOURCES = testoptionalrequired.c
207testoptionalrequired_LDADD = \
Jens Geyer86777192015-07-25 15:59:46 +0200208 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_protocol.o \
209 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
zeshuai007c80b8bb2020-07-23 09:43:41 +0800210 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o \
Roger Meier213a6642010-10-27 12:30:11 +0000211 libtestgenc.la
212
Nobuaki Sukegawa60769702016-01-23 19:25:06 +0900213testthrifttest_SOURCES = testthrifttest.c
214testthrifttest_LDADD = libtestgenc.la \
215 $(top_builddir)/test/c_glib/src/thrift_test_handler.o
Chandler May3fe3df22016-01-18 11:05:40 -0500216testthrifttest_CFLAGS = -I$(top_srcdir)/test/c_glib/src -I./gen-c_glib $(GLIB_CFLAGS)
Roger Meier213a6642010-10-27 12:30:11 +0000217
zeshuai007c80b8bb2020-07-23 09:43:41 +0800218testthriftbinaryreadcheck_SOURCES = testthriftbinaryreadcheck.c
219testthriftbinaryreadcheck_LDADD = \
220 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_protocol.o \
221 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
222 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_framed_transport.o \
223 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_socket.o \
224 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_transport.o \
225 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_socket.o \
226 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
227
228testthriftcompactreadcheck_SOURCES = testthriftcompactreadcheck.c
229testthriftcompactreadcheck_LDADD = \
230 $(top_builddir)/lib/c_glib/src/thrift/c_glib/protocol/libthrift_c_glib_la-thrift_protocol.o \
231 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
232 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_framed_transport.o \
233 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_socket.o \
234 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_transport.o \
235 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_socket.o \
236 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
237
238testthriftbufferedreadcheck_SOURCES = testthriftbufferedreadcheck.c
239testthriftbufferedreadcheck_LDADD = \
240 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
241 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_socket.o \
242 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_transport.o \
243 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_socket.o \
244 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
245
246testthriftfdreadcheck_SOURCES = testthriftfdreadcheck.c
247testthriftfdreadcheck_LDADD = \
248 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
249 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_fd_transport.o \
250 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
251
252testthriftframedreadcheck_SOURCES = testthriftframedreadcheck.c
253testthriftframedreadcheck_LDADD = \
254 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
255 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_socket.o \
256 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_transport.o \
257 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_server_socket.o \
258 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
259
260testthriftmemorybufferreadcheck_SOURCES = testthriftmemorybufferreadcheck.c
261testthriftmemorybufferreadcheck_LDADD = \
262 $(top_builddir)/lib/c_glib/src/thrift/c_glib/transport/libthrift_c_glib_la-thrift_transport.o \
263 $(top_builddir)/lib/c_glib/src/thrift/c_glib/libthrift_c_glib_la-thrift_configuration.o
264
265
Roger Meier213a6642010-10-27 12:30:11 +0000266testthrifttestclient_SOURCES = testthrifttestclient.cpp
267testthrifttestclient_CPPFLAGS = -I../../cpp/src $(BOOST_CPPFLAGS) -I./gen-cpp -I../src -I./gen-c_glib $(GLIB_CFLAGS)
268testthrifttestclient_LDADD = ../../cpp/.libs/libthrift.la ../libthrift_c_glib.la libtestgenc.la libtestgencpp.la
269testthrifttestclient_LDFLAGS = -L../.libs -L../../cpp/.libs $(GLIB_LIBS) $(GOBJECT_LIBS)
270
zeshuai007037753e2020-11-30 11:16:10 +0800271testthrifttestzlibclient_SOURCES = testthrifttestzlibclient.cpp
272testthrifttestzlibclient_CPPFLAGS = -I../../cpp/src $(BOOST_CPPFLAGS) -I./gen-cpp -I../src -I./gen-c_glib $(GLIB_CFLAGS)
273testthrifttestzlibclient_LDADD = ../../cpp/.libs/libthrift.la ../../cpp/.libs/libthriftz.la ../libthrift_c_glib.la libtestgenc.la libtestgencpp.la
274testthrifttestzlibclient_LDFLAGS = -L../.libs -L../../cpp/.libs $(GLIB_LIBS) $(GOBJECT_LIBS)
275
Roger Meier213a6642010-10-27 12:30:11 +0000276check_LTLIBRARIES = libtestgenc.la
277
278if WITH_CPP
279 check_LTLIBRARIES += libtestgencpp.la
280endif
281
Bryan Duxbury39fbb9a2011-01-13 18:09:51 +0000282nodist_libtestgenc_la_SOURCES = \
Jens Geyer54f392b2015-08-05 21:45:10 +0200283 gen-c_glib/t_test_container_test_types.c \
Roger Meier213a6642010-10-27 12:30:11 +0000284 gen-c_glib/t_test_debug_proto_test_types.c \
Nobuaki Sukegawaba3fe862015-12-01 22:42:55 +0900285 gen-c_glib/t_test_enum_test_types.c \
286 gen-c_glib/t_test_enum_test_service.c \
Roger Meier213a6642010-10-27 12:30:11 +0000287 gen-c_glib/t_test_empty_service.c \
288 gen-c_glib/t_test_inherited.c \
289 gen-c_glib/t_test_optional_required_test_types.c \
290 gen-c_glib/t_test_reverse_order_service.c \
291 gen-c_glib/t_test_second_service.c \
292 gen-c_glib/t_test_service_for_exception_with_a_map.c \
293 gen-c_glib/t_test_srv.c \
Jens Geyer54f392b2015-08-05 21:45:10 +0200294 gen-c_glib/t_test_container_service.c \
Roger Meier213a6642010-10-27 12:30:11 +0000295 gen-c_glib/t_test_thrift_test.c \
296 gen-c_glib/t_test_thrift_test_types.c \
Jens Geyer54f392b2015-08-05 21:45:10 +0200297 gen-c_glib/t_test_container_test_types.h \
Roger Meier213a6642010-10-27 12:30:11 +0000298 gen-c_glib/t_test_debug_proto_test_types.h \
Nobuaki Sukegawaba3fe862015-12-01 22:42:55 +0900299 gen-c_glib/t_test_enum_test_types.h \
300 gen-c_glib/t_test_enum_test_service.h \
Roger Meier213a6642010-10-27 12:30:11 +0000301 gen-c_glib/t_test_empty_service.h \
302 gen-c_glib/t_test_inherited.h \
303 gen-c_glib/t_test_optional_required_test_types.h \
304 gen-c_glib/t_test_reverse_order_service.h \
305 gen-c_glib/t_test_second_service.h \
306 gen-c_glib/t_test_service_for_exception_with_a_map.h \
307 gen-c_glib/t_test_srv.h \
Jens Geyer54f392b2015-08-05 21:45:10 +0200308 gen-c_glib/t_test_container_service.h \
Roger Meier213a6642010-10-27 12:30:11 +0000309 gen-c_glib/t_test_thrift_test.h \
310 gen-c_glib/t_test_thrift_test_types.h
311libtestgenc_la_LIBADD = $(top_builddir)/lib/c_glib/libthrift_c_glib.la
Jens Geyer1c190272015-07-28 23:15:18 +0200312libtestgenc_la_CPPFLAGS = $(AM_CPPFLAGS) -Wno-unused-function
Roger Meier213a6642010-10-27 12:30:11 +0000313
Bryan Duxbury39fbb9a2011-01-13 18:09:51 +0000314nodist_libtestgencpp_la_SOURCES = \
Roger Meier213a6642010-10-27 12:30:11 +0000315 gen-cpp/ThriftTest.cpp \
316 gen-cpp/ThriftTest_constants.cpp \
317 gen-cpp/ThriftTest_types.cpp \
318 gen-cpp/ThriftTest.h \
319 gen-cpp/ThriftTest_constants.h \
320 gen-cpp/ThriftTest_types.h
321libtestgencpp_la_CPPFLAGS = -I../../cpp/src $(BOOST_CPPFLAGS) -I./gen-cpp
322
Nobuaki Sukegawa60769702016-01-23 19:25:06 +0900323gen-c_glib/t_test_container_test_types.c gen-c_glib/t_test_container_test_types.h gen-c_glib/t_test_container_service.c gen-c_glib/t_test_container_service.h: ContainerTest.thrift $(THRIFT)
Jens Geyer54f392b2015-08-05 21:45:10 +0200324 $(THRIFT) --gen c_glib $<
325
Nobuaki Sukegawa60769702016-01-23 19:25:06 +0900326gen-c_glib/t_test_debug_proto_test_types.c gen-c_glib/t_test_debug_proto_test_types.h gen-c_glib/t_test_empty_service.c gen-c_glib/t_test_empty_service.h gen-c_glib/t_test_inherited.c gen-c_glib/t_test_inherited.h gen-c_glib/t_test_reverse_order_service.c gen-c_glib/t_test_reverse_order_service.h gen-c_glib/t_test_service_for_exception_with_a_map.c gen-c_glib/t_test_service_for_exception_with_a_map.h gen-c_glib/t_test_srv.c gen-c_glib/t_test_srv.h: ../../../test/DebugProtoTest.thrift $(THRIFT)
Jens Geyer79f988c2014-10-03 20:42:54 +0200327 $(THRIFT) --gen c_glib $<
Roger Meier213a6642010-10-27 12:30:11 +0000328
Nobuaki Sukegawa60769702016-01-23 19:25:06 +0900329gen-c_glib/t_test_enum_test_types.c gen-c_glib/t_test_enum_test_types.h gen-c_glib/t_test_enum_test_service.c gen-c_glib/t_test_enum_test_service.h : ../../../test/EnumTest.thrift $(THRIFT)
Nobuaki Sukegawaba3fe862015-12-01 22:42:55 +0900330 $(THRIFT) --gen c_glib $<
331
Nobuaki Sukegawa60769702016-01-23 19:25:06 +0900332gen-c_glib/t_test_optional_required_test_types.c gen-c_glib/t_test_optional_required_test_types.h: ../../../test/OptionalRequiredTest.thrift $(THRIFT)
Jens Geyer79f988c2014-10-03 20:42:54 +0200333 $(THRIFT) --gen c_glib $<
Roger Meier213a6642010-10-27 12:30:11 +0000334
Nobuaki Sukegawa60769702016-01-23 19:25:06 +0900335gen-c_glib/t_test_second_service.c gen-c_glib/t_test_thrift_test.c gen-c_glib/t_test_thrift_test_types.c gen-c_glib/t_test_second_service.h gen-c_glib/t_test_thrift_test.h gen-c_glib/t_test_thrift_test_types.h: ../../../test/ThriftTest.thrift $(THRIFT)
Jens Geyer79f988c2014-10-03 20:42:54 +0200336 $(THRIFT) --gen c_glib $<
Roger Meier213a6642010-10-27 12:30:11 +0000337
Nobuaki Sukegawa60769702016-01-23 19:25:06 +0900338gen-cpp/ThriftTest.cpp gen-cpp/ThriftTest_constants.cpp gen-cpp/ThriftTest_types.cpp: ../../../test/ThriftTest.thrift $(THRIFT)
Jens Geyer79f988c2014-10-03 20:42:54 +0200339 $(THRIFT) --gen cpp $<
Roger Meier213a6642010-10-27 12:30:11 +0000340
Roger Meier213a6642010-10-27 12:30:11 +0000341TESTS = \
Roger Meier213a6642010-10-27 12:30:11 +0000342 $(check_PROGRAMS) \
343 $(check_SCRIPTS)
344
345# globally added to all instances of valgrind calls
346# VALGRIND_OPTS = --suppressions=glib.suppress
347VALGRIND_OPTS =
348
349# globally added to all memcheck calls
350VALGRIND_MEM_OPTS = --tool=memcheck \
351 --num-callers=10 \
352 ${myextravalgrindmemopts}
353
354# globally added to all leakcheck calls
355VALGRIND_LEAK_OPTS = --tool=memcheck \
356 --num-callers=10 \
357 --leak-check=full \
358 --leak-resolution=high \
359 ${myextravalgrindleakopts}
360
361memcheck: $(check_PROGRAMS)
Jens Geyer79f988c2014-10-03 20:42:54 +0200362 @for x in $(check_PROGRAMS); \
363 do \
364 $(MAKE) memcheck-$$x; \
365 done
Roger Meier213a6642010-10-27 12:30:11 +0000366
367leakcheck: $(check_PROGRAMS)
Jens Geyer79f988c2014-10-03 20:42:54 +0200368 @for x in $(check_PROGRAMS); \
369 do \
370 $(MAKE) leakcheck-$$x; \
371 done
Roger Meier213a6642010-10-27 12:30:11 +0000372
373memcheck-%: %
Jens Geyer79f988c2014-10-03 20:42:54 +0200374 @echo "*****************************************"; \
375 echo "MEMCHECK: $<"; \
376 echo "ARGS: ${VALGRIND_OPTS} ${VALGRIND_MEM_OPTS} ${$<_VALGRIND_MEM_OPTS}"; \
377 $(LIBTOOL) --mode=execute \
378 valgrind \
379 ${VALGRIND_OPTS} \
380 ${VALGRIND_MEM_OPTS} \
381 ${$<_VALGRIND_MEM_OPTS} ./$<
Roger Meier213a6642010-10-27 12:30:11 +0000382
383leakcheck-%: %
Jens Geyer79f988c2014-10-03 20:42:54 +0200384 @echo "*****************************************"; \
385 echo "LEAKCHECK: $<"; \
386 echo "ARGS: ${VALGRIND_OPTS} ${VALGRIND_LEAK_OPTS} ${$<_VALGRIND_LEAK_OPTS}"; \
387 G_SLICE=always-malloc $(LIBTOOL) --mode=execute \
388 valgrind \
389 ${VALGRIND_OPTS} \
390 ${VALGRIND_LEAK_OPTS} \
391 ${$<_VALGRIND_LEAK_OPTS} ./$<
Roger Meier213a6642010-10-27 12:30:11 +0000392
Roger Meier213a6642010-10-27 12:30:11 +0000393clean-local:
Jens Geyer8c5fce92015-07-28 22:59:16 +0200394 $(RM) gen-c_glib/* gen-cpp/*
Roger Meier213a6642010-10-27 12:30:11 +0000395
396CLEANFILES = \
Roger Meier213a6642010-10-27 12:30:11 +0000397 *.bb \
398 *.bbg \
399 *.da \
400 *.gcno \
401 *.gcda \
Roger Meierc1010922010-11-26 10:17:48 +0000402 *.gcov
jfarrellf13e4312015-08-25 00:39:29 -0400403
404EXTRA_DIST = \
405 CMakeLists.txt \
406 ContainerTest.thrift
407