diff -Naur ktorrent-2.2.5/configure.in.in ktorrent-2.2.5.new/configure.in.in --- ktorrent-2.2.5/configure.in.in 2008-01-27 13:06:11.000000000 +0100 +++ ktorrent-2.2.5.new/configure.in.in 2008-01-29 02:05:00.766380548 +0100 @@ -179,26 +179,31 @@ 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 -]) +AC_ARG_WITH([avahi], AS_HELP_STRING([--without-avahi], [Build without avahi/ZeroConf support (default: test)])) -PKG_CHECK_MODULES( AVAHI_QT3, avahi-qt3 >= 0.6.10, -[ - AC_SUBST(AVAHI_QT3_CFLAGS) - AC_SUBST(AVAHI_QT3_LIBS) - avahi=true -], -[ - missing_avahi_warning=yes - avahi=false -]) +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_QT3, avahi-qt3 >= 0.6.10, + [ + AC_SUBST(AVAHI_QT3_CFLAGS) + AC_SUBST(AVAHI_QT3_LIBS) + avahi=true + ], + [ + missing_avahi_warning=yes + avahi=false + ]) +fi AM_CONDITIONAL(COMPILE_ZEROCONF, test x$avahi = xtrue)