specify proper access control rules for conversation service
[oweals/gnunet.git] / src / nat / Makefile.am
1 AM_CPPFLAGS = -I$(top_srcdir)/src/include
2
3 if MINGW
4   WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols
5   NATBIN = gnunet-helper-nat-server gnunet-helper-nat-client
6   NATSERVER = gnunet-helper-nat-server-windows.c
7   NATCLIENT = gnunet-helper-nat-client-windows.c
8 endif
9
10 libexecdir= $(pkglibdir)/libexec/
11
12 pkgcfgdir= $(pkgdatadir)/config.d/
13
14 dist_pkgcfg_DATA = \
15   nat.conf
16
17 if LINUX
18   NATBIN = gnunet-helper-nat-server gnunet-helper-nat-client
19   NATSERVER = gnunet-helper-nat-server.c
20   NATCLIENT = gnunet-helper-nat-client.c
21 install-exec-hook:
22         $(top_srcdir)/src/nat/install-nat-helper.sh $(libexecdir) $(SUDO_BINARY) || true
23 else
24 if XFREEBSD
25   NATBIN = gnunet-helper-nat-server gnunet-helper-nat-client
26   NATSERVER = gnunet-helper-nat-server.c
27   NATCLIENT = gnunet-helper-nat-client.c
28 install-exec-hook:
29         $(top_srcdir)/src/nat/install-nat-helper.sh $(libexecdir) $(SUDO_BINARY) || true
30 endif
31 else
32 install-exec-hook:
33 endif
34
35 bin_PROGRAMS = \
36  gnunet-nat-server 
37
38 libexec_PROGRAMS = \
39  $(NATBIN) 
40
41 gnunet_nat_server_SOURCES = \
42  gnunet-nat-server.c nat.h
43 gnunet_nat_server_LDADD = \
44   $(top_builddir)/src/nat/libgnunetnat.la \
45   $(top_builddir)/src/util/libgnunetutil.la
46 gnunet_nat_server_DEPENDENCIES = \
47   libgnunetnat.la
48
49 gnunet_helper_nat_server_SOURCES = \
50  $(NATSERVER)
51
52 gnunet_helper_nat_client_SOURCES = \
53  $(NATCLIENT)         
54
55
56
57 if USE_COVERAGE
58   AM_CFLAGS = -fprofile-arcs -ftest-coverage
59 endif
60
61 lib_LTLIBRARIES = libgnunetnat.la
62
63 libgnunetnat_la_SOURCES = \
64   nat.c nat.h \
65   nat_auto.c \
66   nat_test.c \
67   nat_mini.c 
68
69 libgnunetnat_la_LIBADD = \
70   $(top_builddir)/src/util/libgnunetutil.la \
71   $(GN_LIBINTL) @EXT_LIBS@ 
72
73 libgnunetnat_la_LDFLAGS = \
74   $(GN_LIB_LDFLAGS) $(WINFLAGS) \
75   -version-info 1:0:1
76
77 check_PROGRAMS = \
78   test_nat \
79   test_nat_mini \
80   test_nat_test
81
82 if ENABLE_TEST_RUN
83  TESTS = $(check_PROGRAMS)
84 endif
85
86 test_nat_SOURCES = \
87   test_nat.c
88 test_nat_LDADD = \
89  $(top_builddir)/src/nat/libgnunetnat.la \
90  $(top_builddir)/src/util/libgnunetutil.la 
91
92 test_nat_mini_SOURCES = \
93   test_nat_mini.c
94 test_nat_mini_LDADD = \
95  $(top_builddir)/src/nat/libgnunetnat.la \
96  $(top_builddir)/src/util/libgnunetutil.la 
97
98
99 test_nat_test_SOURCES = \
100   test_nat_test.c
101 test_nat_test_LDADD = \
102  $(top_builddir)/src/nat/libgnunetnat.la \
103  $(top_builddir)/src/util/libgnunetutil.la 
104
105
106 EXTRA_DIST = \
107  test_nat_data.conf \
108  test_nat_test_data.conf