summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDarrell Anderson <[email protected]>2013-08-13 20:29:57 -0500
committerDarrell Anderson <[email protected]>2013-08-13 20:29:57 -0500
commit1bedc512309ee3a13d61397235833b59f7d8ee9b (patch)
treecc4c5488d19523daa87f2fbb34a506d938f7f56f
parente0c9cb1b1847592ad0a0ee62689a03b45c175c7d (diff)
downloadktorrent-1bedc512309ee3a13d61397235833b59f7d8ee9b.tar.gz
ktorrent-1bedc512309ee3a13d61397235833b59f7d8ee9b.zip
Add an explicit --disable-avahi to the configuration options.
Previous defaults remain --- the option must be explicitly defined to be used. Thanks to E. Liddell.
-rw-r--r--configure.in.in49
1 files changed, 27 insertions, 22 deletions
diff --git a/configure.in.in b/configure.in.in
index f4a6e1d..1cab8c0 100644
--- a/configure.in.in
+++ b/configure.in.in
@@ -98,7 +98,7 @@ KDE_CHECK_LIB(gmp, __gmpz_init, [have_gmp=yes],
AC_MSG_ERROR(libgmp is required to install this program)
])
-KDE_CHECK_HEADER(gmp.h, [have_gmp=yes],
+KDE_CHECK_HEADER(gmp.h, [have_gmp=yes],
[
have_gmp=no
AC_MSG_ERROR(libgmp is required to install this program)
@@ -198,26 +198,31 @@ fi
m4_pattern_allow(PKG_CONFIG_MIN_VERSION)
PKG_PROG_PKG_CONFIG
-PKG_CHECK_MODULES( AVAHI, avahi-client >= 0.6.10,
-[
- AC_SUBST(AVAHI_CFLAGS)
- AC_SUBST(AVAHI_LIBS)
- avahi=true
-],
-[
- missing_avahi_warning=yes
- avahi=false
-])
-
-PKG_CHECK_MODULES( AVAHI_TQT, avahi-tqt >= 0.6.10,
-[
- AC_SUBST(AVAHI_TQT_CFLAGS)
- AC_SUBST(AVAHI_TQT_LIBS)
- avahi=true
-],
-[
- missing_avahi_warning=yes
- avahi=false
-])
+AC_ARG_WITH([avahi], AS_HELP_STRING([--without-avahi], [Build without avahi/ZeroConf support (default: test)]))
+
+avahi=false
+if test "x$with_avahi" != "xno"; then
+ PKG_CHECK_MODULES( AVAHI, avahi-client >= 0.6.10,
+ [
+ AC_SUBST(AVAHI_CFLAGS)
+ AC_SUBST(AVAHI_LIBS)
+ avahi=true
+ ],
+ [
+ missing_avahi_warning=yes
+ avahi=false
+ ])
+
+ PKG_CHECK_MODULES( AVAHI_TQT, avahi-tqt >= 0.6.10,
+ [
+ AC_SUBST(AVAHI_TQT_CFLAGS)
+ AC_SUBST(AVAHI_TQT_LIBS)
+ avahi=true
+ ],
+ [
+ missing_avahi_warning=yes
+ avahi=false
+ ])
+fi
AM_CONDITIONAL(COMPILE_ZEROCONF, test x$avahi = xtrue)