clean up python logic a bit, remove duplicate print() calls when we have log calls
[oweals/gnunet.git] / src / integration-tests / Makefile.am
1 # This Makefile.am is in the public domain
2 AM_CPPFLAGS = -I$(top_srcdir)/src/include
3
4 if MINGW
5  WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols
6 endif
7
8 if USE_COVERAGE
9   AM_CFLAGS = --coverage -O0
10   XLIB = -lgcov
11 endif
12
13 noinst_SCRIPTS = \
14  gnunet_testing.py \
15  gnunet_pyexpect.py
16
17 if HAVE_PYTHON
18 check_SCRIPTS = \
19   test_integration_bootstrap_and_connect.py \
20   test_integration_disconnect.py \
21   test_integration_disconnect_nat.py \
22   test_integration_reconnect.py \
23   test_integration_reconnect_nat.py \
24   test_integration_clique.py
25 endif
26
27
28 if HAVE_MHD
29 if ENABLE_TEST_RUN
30 AM_TESTS_ENVIRONMENT=export GNUNET_PREFIX=$${GNUNET_PREFIX:-@libdir@};export PATH=$${GNUNET_PREFIX:-@prefix@}/bin:$$PATH;unset XDG_DATA_HOME;unset XDG_CONFIG_HOME;
31 if HAVE_LIBGNURL
32 TESTS = \
33  $(check_SCRIPTS)
34 else
35 if HAVE_LIBCURL
36 TESTS = \
37  $(check_SCRIPTS)
38 endif
39 endif
40 endif
41 endif
42
43 do_subst = $(SED) -e 's,[@]PYTHON[@],$(PYTHON),g'
44
45 SUFFIXES = .py.in .py
46 .py.in.py:
47         $(do_subst) < $(srcdir)/$< > $@
48         chmod +x $@
49
50 gnunet_testing.py: gnunet_testing.py.in Makefile
51         $(do_subst) < $(srcdir)/gnunet_testing.py.in > gnunet_testing.py
52         chmod +x gnunet_testing.py
53
54 gnunet_pyexpect.py: gnunet_pyexpect.py.in Makefile
55         $(do_subst) < $(srcdir)/gnunet_pyexpect.py.in > gnunet_pyexpect.py
56         chmod +x gnunet_pyexpect.py
57
58 test_integration_bootstrap_and_connect.py: test_integration_bootstrap_and_connect.py.in Makefile
59         $(do_subst) < $(srcdir)/test_integration_bootstrap_and_connect.py.in > test_integration_bootstrap_and_connect.py
60         chmod +x test_integration_bootstrap_and_connect.py
61
62 test_integration_disconnect.py: test_integration_disconnect.py.in Makefile
63         $(do_subst) < $(srcdir)/test_integration_disconnect.py.in > test_integration_disconnect.py
64         chmod +x test_integration_disconnect.py
65
66 test_integration_disconnect_nat.py: test_integration_disconnect_nat.py.in Makefile
67         $(do_subst) < $(srcdir)/test_integration_disconnect_nat.py.in > test_integration_disconnect_nat.py
68         chmod +x test_integration_disconnect_nat.py
69
70 test_integration_reconnect.py: test_integration_reconnect.py.in Makefile
71         $(do_subst) < $(srcdir)/test_integration_reconnect.py.in > test_integration_reconnect.py
72         chmod +x test_integration_reconnect.py
73
74 test_integration_reconnect_nat.py: test_integration_reconnect_nat.py.in Makefile
75         $(do_subst) < $(srcdir)/test_integration_reconnect_nat.py.in > test_integration_reconnect_nat.py
76         chmod +x test_integration_reconnect_nat.py
77
78 test_integration_clique.py: test_integration_clique.py.in Makefile
79         $(do_subst) < $(srcdir)/test_integration_clique.py.in > test_integration_clique.py
80         chmod +x test_integration_clique.py
81
82
83 EXTRA_DIST = \
84    gnunet_testing.py.in \
85    gnunet_pyexpect.py.in \
86    test_integration_bootstrap_and_connect.py.in \
87    test_integration_disconnect.py.in \
88    test_integration_disconnect_nat.py.in \
89    test_integration_reconnect.py.in \
90    test_integration_reconnect_nat.py.in \
91    test_integration_clique.py.in \
92    confs/test_defaults.conf \
93    confs/c_bootstrap_server.conf \
94    confs/c_nat_client.conf \
95    confs/c_no_nat_client_2.conf \
96    confs/c_no_nat_client.conf \
97    hostkeys/c_bootstrap_server \
98    hostkeys/c_no_nat_client \
99    hostkeys/c_no_nat_client_2 \
100    hostkeys/c_nat_client
101
102 CLEANFILES = \
103         $(check_SCRIPTS) \
104         gnunet_pyexpect.py \
105         gnunet_testing.py