]> granicus.if.org Git - mutt/commitdiff
Add autoconf check for libunistring when checking for idn2.
authorKevin McCarthy <kevin@8t8.us>
Tue, 21 Aug 2018 22:00:23 +0000 (15:00 -0700)
committerKevin McCarthy <kevin@8t8.us>
Tue, 21 Aug 2018 22:00:23 +0000 (15:00 -0700)
-lunistring is only explicitly needed when compiling statically, so
add a AC_SEARCH_LIBS to add it to LIBS if it is found.

Thanks to Fabrice Fontaine for the heads-up about the problem and the
merge request.

configure.ac

index 41550180b21de534701ac3604c3459172b3811df..3e477f2fbdbb6125a8758b342452a37d604bc6a1 100644 (file)
@@ -1367,6 +1367,8 @@ if test "x$with_idn2" != "xno"; then
 
     AC_SEARCH_LIBS([idn2_check_version], [idn2], [
       AC_DEFINE([HAVE_LIBIDN2], 1, [Define to 1 if you have the GNU idn2 library])
+      dnl -lunistring is needed for static linking
+      AC_SEARCH_LIBS([u8_strconv_from_locale], [unistring])
       MUTTLIBS="$MUTTLIBS $LIBS"
 
       dnl libidn2 >= 2.0.0 declares compatibility macros in idn2.h