X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=blobdiff_plain;f=configure.ac;h=6d5536b59922dbe979ac5ec648356fefd3734698;hp=0802cfcc9846e617d41e2c9d71011681b54c3621;hb=c2d6bd61ee77b59566116afe6e20513d19945ed4;hpb=a59f16ce4a11c440cb2136ad3d5e3184714c545e diff --git a/configure.ac b/configure.ac index 0802cfcc9..6d5536b59 100644 --- a/configure.ac +++ b/configure.ac @@ -810,6 +810,21 @@ if test "x$enable_libcurl" != "xno"; then fi AM_CONDITIONAL(HAVE_LIBCURL, [test "$have_libcurl" = "yes"]) +# ------------------------------------------------------------------------------ +have_libidn=no +AC_ARG_ENABLE(libidn, AS_HELP_STRING([--disable-libidn], [Disable optional LIBIDN support])) +if test "x$enable_libidn" != "xno"; then + PKG_CHECK_MODULES(LIBIDN, [libidn], + [AC_DEFINE(HAVE_LIBIDN, 1, [Define if libidn is available]) + have_libidn=yes + M4_DEFINES="$M4_DEFINES -DHAVE_LIBIDN"], + [have_libidn=no]) + if test "x$have_libidn" = "xno" -a "x$enable_libidn" = "xyes"; then + AC_MSG_ERROR([*** libidn support requested but libraries not found]) + fi +fi +AM_CONDITIONAL(HAVE_LIBIDN, [test "$have_libidn" = "yes"]) + # ------------------------------------------------------------------------------ have_binfmt=no AC_ARG_ENABLE(binfmt, AS_HELP_STRING([--disable-binfmt], [disable binfmt tool])) @@ -1326,6 +1341,7 @@ AC_MSG_RESULT([ CHKCONFIG: ${have_chkconfig} GNUTLS: ${have_gnutls} libcurl: ${have_libcurl} + libidn: ${have_libidn} ELFUTILS: ${have_elfutils} binfmt: ${have_binfmt} vconsole: ${have_vconsole}