builds: only enable TAP driver for glib >= 2.37.6
authorLubomir Rintel <lkundrak@v3.sk>
Tue, 26 May 2015 13:21:12 +0000 (15:21 +0200)
committerLubomir Rintel <lkundrak@v3.sk>
Thu, 28 May 2015 10:51:24 +0000 (12:51 +0200)
No TAP support for previous versions and --tap argument is silently ignored,
confusing the TAP driver.

18 files changed:
callouts/tests/Makefile.am
configure.ac
libnm-core/tests/Makefile.am
libnm-glib/tests/Makefile.am
libnm-util/tests/Makefile.am
libnm/tests/Makefile.am
src/devices/wifi/tests/Makefile.am
src/dhcp-manager/tests/Makefile.am
src/dnsmasq-manager/tests/Makefile.am
src/platform/tests/Makefile.am
src/rdisc/tests/Makefile.am
src/settings/plugins/ibft/tests/Makefile.am
src/settings/plugins/ifcfg-rh/tests/Makefile.am
src/settings/plugins/ifupdown/tests/Makefile.am
src/settings/plugins/keyfile/tests/Makefile.am
src/supplicant-manager/tests/Makefile.am
src/tests/Makefile.am
src/tests/config/Makefile.am

index f3169d7..a0ed401 100644 (file)
@@ -29,8 +29,6 @@ test_dispatcher_envp_LDADD = \
 ###########################################
 
 @VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = test-dispatcher-envp
 
 endif
index dd10f09..5f2eb2e 100644 (file)
@@ -278,7 +278,11 @@ else
 fi
 AM_CONDITIONAL(HAVE_DBUS_GLIB_100, test "${have_dbus_glib_100}" = "yes")
 
-PKG_CHECK_MODULES(GLIB, gio-unix-2.0 >= 2.32 gmodule-2.0)
+PKG_CHECK_MODULES(GLIB, [gio-unix-2.0 >= 2.37.6 gmodule-2.0],
+       [AC_SUBST(LOG_DRIVER, '$(top_srcdir)/build-aux/tap-driver.sh'),
+        AC_SUBST(AM_TESTS_FD_REDIRECT, '--tap')],
+       [PKG_CHECK_MODULES(GLIB, gio-unix-2.0 >= 2.32 gmodule-2.0)
+        AC_SUBST(LOG_DRIVER, '$(top_srcdir)/build-aux/test-driver')])
 
 dnl GLIB_VERSION_MIN_REQUIRED should match the version above.
 dnl GLIB_VERSION_MAX_ALLOWED should be set to the same version;
index 13e3c01..daa5825 100644 (file)
@@ -26,8 +26,6 @@ LDADD = \
        $(GLIB_LIBS)
 
 @VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = $(noinst_PROGRAMS)
 
 endif
index a01a50e..7168d3d 100644 (file)
@@ -17,8 +17,6 @@ if WITH_VALGRIND
 else
 LOG_COMPILER = $(srcdir)/libnm-glib-test-launch.sh
 endif
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = test-nm-client test-remote-settings-client
 
 ####### NMClient and non-settings tests #######
index f90fe8b..16a7f8f 100644 (file)
@@ -11,8 +11,6 @@ AM_CPPFLAGS = \
        -DTEST_CERT_DIR=\"$(top_srcdir)/libnm-core/tests/certs/\"
 
 @VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = \
        test-settings-defaults \
        test-crypto \
index 0e7db21..a2dafec 100644 (file)
@@ -22,8 +22,6 @@ if WITH_VALGRIND
 else
 LOG_COMPILER = $(srcdir)/libnm-test-launch.sh
 endif
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = test-nm-client test-remote-settings-client test-secret-agent
 
 test_nm_client_SOURCES = \
index 72dc718..2a7d784 100644 (file)
@@ -24,7 +24,5 @@ test_wifi_ap_utils_SOURCES = \
 test_wifi_ap_utils_LDADD = $(top_builddir)/src/libNetworkManager.la
 
 @VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = test-wifi-ap-utils
 
index 2fb39e0..8aa79a2 100644 (file)
@@ -38,8 +38,6 @@ test_dhcp_utils_LDADD = \
 #################################
 
 @VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = test-dhcp-dhclient test-dhcp-utils
 
 EXTRA_DIST = \
index ed12255..b51de6a 100644 (file)
@@ -20,7 +20,5 @@ test_dnsmasq_utils_LDADD = \
        $(top_builddir)/src/libNetworkManager.la
 
 @VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = test-dnsmasq-utils
 
index bc032d2..92400f9 100644 (file)
@@ -110,8 +110,6 @@ test_cleanup_linux_CPPFLAGS = \
 test_cleanup_linux_LDADD = $(PLATFORM_LDADD)
 
 @VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = \
        test-address-fake \
        test-address-linux \
index e10b34f..5d6f8b5 100644 (file)
@@ -33,7 +33,5 @@ test_rdisc_fake_LDADD = \
        $(top_builddir)/src/libNetworkManager.la
 
 @VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = test-rdisc-fake
 
index e7285e0..3c7c94a 100644 (file)
@@ -33,8 +33,6 @@ test_ibft_LDADD = \
        $(top_builddir)/src/libNetworkManager.la
 
 @VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = test-ibft
 
 endif
index f629830..a3f6a05 100644 (file)
@@ -48,8 +48,6 @@ test_ifcfg_rh_utils_LDADD = \
        $(top_builddir)/src/libNetworkManager.la
 
 @VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = test-ifcfg-rh-utils test-ifcfg-rh
 
 endif
index e43a511..2e927db 100644 (file)
@@ -25,8 +25,6 @@ test_ifupdown_LDADD = \
 
 # TODO: enable valgrind for ifupdown. Currently it fails.
 #@VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = test-ifupdown
 
 endif
index dffa276..a79e20b 100644 (file)
@@ -35,8 +35,6 @@ test_keyfile_LDADD = \
        $(CODE_COVERAGE_LDFLAGS)
 
 @VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = test-keyfile
 
 endif
index d53b7ff..85268dc 100644 (file)
@@ -19,6 +19,4 @@ test_supplicant_config_LDADD = \
        $(top_builddir)/src/libNetworkManager.la
 
 @VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = test-supplicant-config
index fdda3b0..83632bd 100644 (file)
@@ -117,8 +117,6 @@ EXTRA_DIST = test-secret-agent.py
 ###########################################
 
 @VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = \
        test-ip4-config \
        test-ip6-config \
index 5936624..42c6b9a 100644 (file)
@@ -24,8 +24,6 @@ test_config_LDADD = \
        $(top_builddir)/src/libNetworkManager.la
 
 @VALGRIND_RULES@
-AM_TESTS_FD_REDIRECT = --tap
-LOG_DRIVER = $(top_srcdir)/build-aux/tap-driver.sh
 TESTS = test-config
 
 EXTRA_DIST = \