fixing mess with search update serialization and parenting
[oweals/gnunet.git] / src / transport / Makefile.am
1 INCLUDES = -I$(top_srcdir)/src/include
2
3 plugindir = $(libdir)/gnunet
4
5 if MINGW
6   WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols
7 endif
8
9 if HAVE_MHD 
10  GN_LIBMHD = -lmicrohttpd
11  HTTP_PLUGIN_LA = libgnunet_plugin_transport_http.la
12  HTTP_PLGUIN_CHECK = test_plugin_transport_http
13 endif
14
15 if USE_COVERAGE
16   AM_CFLAGS = --coverage -O0
17 endif
18
19 if LINUX
20 NATBIN = gnunet-nat-server gnunet-nat-client
21 install-exec-hook:
22         chown root $(bindir)/gnunet-nat-server $(bindir)/gnunet-nat-client || true
23         chmod u+s $(bindir)/gnunet-nat-server $(bindir)/gnunet-nat-client || true
24 else
25 install-exec-hook:
26 endif
27
28
29 lib_LTLIBRARIES = \
30   libgnunettransport.la
31
32 libgnunettransport_la_SOURCES = \
33   transport_api.c transport.h \
34   transport_api_blacklist.c \
35   transport_api_address_lookup.c 
36 libgnunettransport_la_LIBADD = \
37   $(top_builddir)/src/arm/libgnunetarm.la \
38   $(top_builddir)/src/hello/libgnunethello.la \
39   $(top_builddir)/src/util/libgnunetutil.la \
40   $(GN_LIBINTL) 
41 libgnunettransport_la_LDFLAGS = \
42   $(GN_LIB_LDFLAGS) $(WINFLAGS) \
43   -version-info 0:0:0
44
45
46 bin_PROGRAMS = \
47  gnunet-transport \
48  gnunet-service-transport $(NATBIN)
49
50
51 gnunet_nat_server_SOURCES = \
52  gnunet-nat-server.c         
53
54 gnunet_nat_client_SOURCES = \
55  gnunet-nat-client.c         
56
57
58 gnunet_transport_SOURCES = \
59  gnunet-transport.c         
60 gnunet_transport_LDADD = \
61   $(top_builddir)/src/transport/libgnunettransport.la \
62   $(top_builddir)/src/util/libgnunetutil.la \
63   $(GN_LIBINTL)
64
65 gnunet_service_transport_SOURCES = \
66  gnunet-service-transport.c plugin_transport.h 
67 gnunet_service_transport_LDADD = \
68   $(top_builddir)/src/peerinfo/libgnunetpeerinfo.la \
69   $(top_builddir)/src/statistics/libgnunetstatistics.la \
70   $(top_builddir)/src/util/libgnunetutil.la \
71   $(GN_LIBINTL)
72
73
74 plugin_LTLIBRARIES = \
75   libgnunet_plugin_transport_tcp.la \
76   libgnunet_plugin_transport_udp.la \
77   libgnunet_plugin_transport_udp_nat.la \
78   $(HTTP_PLUGIN_LA) \
79   libgnunet_plugin_transport_template.la
80 # TODO: add http, nat, etc.
81
82 libgnunet_plugin_transport_tcp_la_SOURCES = \
83   plugin_transport_tcp.c
84 libgnunet_plugin_transport_tcp_la_LIBADD = \
85   $(top_builddir)/src/hello/libgnunethello.la \
86   $(top_builddir)/src/statistics/libgnunetstatistics.la \
87   $(top_builddir)/src/peerinfo/libgnunetpeerinfo.la \
88   $(top_builddir)/src/util/libgnunetutil.la 
89 libgnunet_plugin_transport_tcp_la_LDFLAGS = \
90  $(GN_PLUGIN_LDFLAGS)
91
92 libgnunet_plugin_transport_template_la_SOURCES = \
93   plugin_transport_template.c
94 libgnunet_plugin_transport_template_la_LIBADD = \
95   $(top_builddir)/src/util/libgnunetutil.la 
96 libgnunet_plugin_transport_template_la_LDFLAGS = \
97  $(GN_PLUGIN_LDFLAGS)
98
99 libgnunet_plugin_transport_udp_la_SOURCES = \
100   plugin_transport_udp.c
101 libgnunet_plugin_transport_udp_la_LIBADD = \
102   $(top_builddir)/src/hello/libgnunethello.la \
103   $(top_builddir)/src/statistics/libgnunetstatistics.la \
104   $(top_builddir)/src/peerinfo/libgnunetpeerinfo.la \
105   $(top_builddir)/src/util/libgnunetutil.la 
106 libgnunet_plugin_transport_udp_la_LDFLAGS = \
107  $(GN_PLUGIN_LDFLAGS)
108
109 libgnunet_plugin_transport_udp_nat_la_SOURCES = \
110   plugin_transport_udp_nat.c
111 libgnunet_plugin_transport_udp_nat_la_LIBADD = \
112   $(top_builddir)/src/hello/libgnunethello.la \
113   $(top_builddir)/src/statistics/libgnunetstatistics.la \
114   $(top_builddir)/src/peerinfo/libgnunetpeerinfo.la \
115   $(top_builddir)/src/util/libgnunetutil.la 
116 libgnunet_plugin_transport_udp_nat_la_LDFLAGS = \
117  $(GN_PLUGIN_LDFLAGS)
118
119 if HAVE_MHD 
120 libgnunet_plugin_transport_http_la_SOURCES = \
121   plugin_transport_http.c
122 libgnunet_plugin_transport_http_la_LIBADD = \
123   $(top_builddir)/src/hello/libgnunethello.la \
124   $(top_builddir)/src/statistics/libgnunetstatistics.la \
125   $(top_builddir)/src/peerinfo/libgnunetpeerinfo.la \
126   @LIBCURL@ \
127   $(top_builddir)/src/util/libgnunetutil.la 
128 libgnunet_plugin_transport_http_la_LDFLAGS = \
129  $(GN_LIBMHD) \
130  $(GN_PLUGIN_LDFLAGS)
131 endif
132  
133 check_PROGRAMS = \
134  test_transport_api_tcp \
135  test_transport_api_udp \
136  $(HTTP_PLGUIN_CHECK) \ 
137  test_transport_api_udp_nat
138 # test_transport_api_http \
139 # TODO: add tests for http, nat, etc.
140
141 TESTS = $(check_PROGRAMS)
142
143 test_transport_api_tcp_SOURCES = \
144  test_transport_api.c
145 test_transport_api_tcp_LDADD = \
146  $(top_builddir)/src/transport/libgnunettransport.la \
147  $(top_builddir)/src/util/libgnunetutil.la  
148
149 test_transport_api_udp_SOURCES = \
150  test_transport_api.c
151 test_transport_api_udp_LDADD = \
152  $(top_builddir)/src/transport/libgnunettransport.la \
153  $(top_builddir)/src/util/libgnunetutil.la  
154
155 test_transport_api_udp_nat_SOURCES = \
156  test_transport_api.c
157 test_transport_api_udp_nat_LDADD = \
158  $(top_builddir)/src/transport/libgnunettransport.la \
159  $(top_builddir)/src/util/libgnunetutil.la  
160  
161 #test_transport_api_http_SOURCES = \
162 # test_transport_api.c
163 #test_transport_api_http_LDADD = \
164 # $(top_builddir)/src/transport/libgnunettransport.la \
165 # $(top_builddir)/src/util/libgnunetutil.la  
166
167 test_plugin_transport_http_SOURCES = \
168  test_plugin_transport_http.c
169 test_plugin_transport_http_LDADD = \
170  $(top_builddir)/src/transport/libgnunettransport.la \
171  $(top_builddir)/src/statistics/libgnunetstatistics.la \
172  $(top_builddir)/src/util/libgnunetutil.la  
173
174
175 EXTRA_DIST = \
176   test_transport_api_data.conf \
177   test_transport_api_tcp_peer1.conf \
178   test_transport_api_tcp_peer2.conf \
179   test_transport_api_udp_peer1.conf \
180   test_transport_api_udp_peer2.conf \
181   test_transport_api_udp_nat_peer1.conf \
182   test_transport_api_udp_nat_peer2.conf \
183   test_plugin_transport_data.conf \
184   test_plugin_transport_data_http.conf