]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
configure: Fix dcrypt build
authorAki Tuomi <aki.tuomi@dovecot.fi>
Thu, 11 Aug 2016 11:28:24 +0000 (14:28 +0300)
committerAki Tuomi <aki.tuomi@dovecot.fi>
Thu, 11 Aug 2016 11:28:36 +0000 (14:28 +0300)
configure.ac
src/Makefile.am
src/lib-dcrypt/Makefile.am

index 45dad880b94b86fda0889c7a1820df8f13af5d3c..5add63a192b4fd29013a7ea8bb56294952ba5f66 100644 (file)
@@ -1677,6 +1677,7 @@ dnl ** SSL
 dnl **
 
 have_ssl=no
+build_dcrypt_openssl=no
 
 if test $want_openssl != no && test $have_ssl = no; then
   if test "$PKG_CONFIG" != "" && $PKG_CONFIG --exists openssl 2>/dev/null; then
@@ -1704,7 +1705,7 @@ if test $want_openssl != no && test $have_ssl = no; then
   if test "$have_openssl" = "yes"; then
     AC_DEFINE(HAVE_OPENSSL,, [Build with OpenSSL support])
     have_ssl="yes (OpenSSL)"
-    build_dcrypt="no"
+    build_dcrypt_openssl="no"
 
     AC_CHECK_LIB(ssl, SSL_get_current_compression, [
       AC_DEFINE(HAVE_SSL_COMPRESSION,, [Build with OpenSSL compression])
@@ -1716,13 +1717,14 @@ if test $want_openssl != no && test $have_ssl = no; then
       AC_DEFINE(HAVE_SSL_COMP_FREE_COMPRESSION_METHODS,, [Build with SSL_COMP_free_compression_methods() support])
     ],, $SSL_LIBS)
     AC_CHECK_LIB(ssl, [EC_KEY_new],
-       [build_dcrypt="yes"],
+       [build_dcrypt_openssl="yes"],
        AC_MSG_WARN([No ECC support in OpenSSL - not enabling dcrypt]),
     $SSL_LIBS)
   fi
 fi
+
 AM_CONDITIONAL(BUILD_OPENSSL, test "$have_openssl" = "yes")
-AM_CONDITIONAL(HAVE_DCRYPT, test "$build_dcrypt" != "no")
+AM_CONDITIONAL(BUILD_DCRYPT_OPENSSL, test "$build_dcrypt_openssl" = "yes")
 
 if test $want_gnutls != no && test $have_ssl = no; then
   AC_CHECK_LIB(gnutls, gnutls_global_init, [
@@ -2544,13 +2546,8 @@ dnl **
 dnl ** Shared libraries usage
 dnl **
 
-if test "$build_dcrypt" = "yes"; then
-  lib_dcrypt='$(top_builddir)/src/lib-dcrypt/libdcrypt.la'
-fi
-
 
-LIBDOVECOT_LA_LIBS='$(top_builddir)/src/lib-dict-extra/libdict_extra.la $(top_builddir)/src/lib-master/libmaster.la $(top_builddir)/src/lib-settings/libsettings.la $(top_builddir)/src/lib-stats/libstats.la $(top_builddir)/src/lib-http/libhttp.la $(top_builddir)/src/lib-fs/libfs.la $(top_builddir)/src/lib-dict/libdict.la $(top_builddir)/src/lib-dns/libdns.la $(top_builddir)/src/lib-imap/libimap.la $(top_builddir)/src/lib-mail/libmail.la $(top_builddir)/src/lib-sasl/libsasl.la $(top_builddir)/src/lib-auth/libauth.la $(top_builddir)/src/lib-charset/libcharset.la $(top_builddir)/src/lib-ssl-iostream/libssl_iostream.la'
-LIBDOVECOT_LA_LIBS="$LIBDOVECOT_LA_LIBS $lib_dcrypt \$(top_builddir)/src/lib-test/libtest.la \$(top_builddir)/src/lib/liblib.la"
+LIBDOVECOT_LA_LIBS='$(top_builddir)/src/lib-dict-extra/libdict_extra.la $(top_builddir)/src/lib-master/libmaster.la $(top_builddir)/src/lib-settings/libsettings.la $(top_builddir)/src/lib-stats/libstats.la $(top_builddir)/src/lib-http/libhttp.la $(top_builddir)/src/lib-fs/libfs.la $(top_builddir)/src/lib-dict/libdict.la $(top_builddir)/src/lib-dns/libdns.la $(top_builddir)/src/lib-imap/libimap.la $(top_builddir)/src/lib-mail/libmail.la $(top_builddir)/src/lib-sasl/libsasl.la $(top_builddir)/src/lib-auth/libauth.la $(top_builddir)/src/lib-charset/libcharset.la $(top_builddir)/src/lib-ssl-iostream/libssl_iostream.la $(top_builddir)/src/lib-dcrypt/libdcrypt.la $(top_builddir)/src/lib-test/libtest.la $(top_builddir)/src/lib/liblib.la'
 
 if test "$want_shared_libs" = "yes"; then
   LIBDOVECOT_DEPS='$(top_builddir)/src/lib-dovecot/libdovecot.la'
@@ -3014,7 +3011,7 @@ echo "I/O notifys .... : $have_notify"
 echo "SSL ............ : $have_ssl"
 echo "GSSAPI ......... : $have_gssapi"
 echo "passdbs ........ :$passdb"
-echo "dcrypt ..........: $build_dcrypt"
+echo "dcrypt ..........: $build_dcrypt_openssl"
 
 if test "$not_passdb" != ""; then
   echo "                 :$not_passdb"
index 3f462383b71f8e75fa12f306255dedac94237e38..dd76173d8a46afafb179b3e63151efc675c8d340 100644 (file)
@@ -2,10 +2,6 @@ if HAVE_LDAP
 LIB_LDAP=lib-ldap
 endif
 
-if HAVE_DCRYPT
-LIB_DCRYPT=lib-dcrypt
-endif
-
 LIBDOVECOT_SUBDIRS = \
        lib-test \
        lib \
@@ -14,7 +10,7 @@ LIBDOVECOT_SUBDIRS = \
        lib-master \
        lib-charset \
        lib-ssl-iostream \
-       $(LIB_DCRYPT) \
+       lib-dcrypt \
        lib-dns \
        lib-dict \
        lib-sasl \
index 7a538a0255cd39d878939f4c23837d521acc1028..e28ca2d3cb355de2208c2407fc8f1c87fdcc04f4 100644 (file)
@@ -16,7 +16,7 @@ libdcrypt_la_CFLAGS = $(AM_CPPFLAGS) \
 
 libdcrypt_la_LDFLAGS = -export-dynamic
 
-if BUILD_OPENSSL
+if BUILD_DCRYPT_OPENSSL
 pkglib_LTLIBRARIES += libdcrypt_openssl.la
 libdcrypt_openssl_la_SOURCES = dcrypt-openssl.c dcrypt.c
 libdcrypt_openssl_la_LDFLAGS = -module -avoid-version -shared ../lib-ssl-iostream/libdovecot_openssl_common.la ../lib/liblib.la