]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
Fixed --with-ldap=plugin and --with-gssapi=plugin
authorTimo Sirainen <tss@iki.fi>
Thu, 26 Mar 2009 22:36:36 +0000 (18:36 -0400)
committerTimo Sirainen <tss@iki.fi>
Thu, 26 Mar 2009 22:36:36 +0000 (18:36 -0400)
--HG--
branch : HEAD

src/auth/Makefile.am
src/auth/db-ldap.c
src/auth/mech-gssapi.c
src/auth/passdb-ldap.c
src/auth/userdb-ldap.c

index e9e626f17807e31d837f8456869619f19e10cf25..ae7f52ce4e0f516e3cd16929e5f9f53513b0e9c4 100644 (file)
@@ -48,14 +48,6 @@ dovecot_auth_LDADD = \
 
 ldap_sources = db-ldap.c passdb-ldap.c userdb-ldap.c
 
-if ! LDAP_PLUGIN
-builtin_ldap_sources = $(ldap_sources)
-endif
-
-if ! GSSAPI_PLUGIN
-builtin_gssapi_sources = mech-gssapi.c
-endif
-
 dovecot_auth_SOURCES = \
        auth.c \
        auth-cache.c \
@@ -77,6 +69,7 @@ dovecot_auth_SOURCES = \
        mech-login.c \
        mech-cram-md5.c \
        mech-digest-md5.c \
+       mech-gssapi.c \
        mech-ntlm.c \
        mech-otp.c \
        mech-skey.c \
@@ -107,8 +100,7 @@ dovecot_auth_SOURCES = \
        userdb-static.c \
        userdb-vpopmail.c \
        userdb-sql.c \
-       $(builtin_gssapi_sources) \
-       $(builtin_ldap_sources)
+       $(ldap_sources)
 
 headers = \
        auth.h \
@@ -144,14 +136,14 @@ headers = \
 if GSSAPI_PLUGIN
 libmech_gssapi_la_LDFLAGS = -module -avoid-version
 libmech_gssapi_la_LIBADD = $(KRB5_LIBS)
-libmech_gssapi_la_CPPFLAGS = $(AM_CPPFLAGS) $(KRB5_CFLAGS)
+libmech_gssapi_la_CPPFLAGS = $(AM_CPPFLAGS) $(KRB5_CFLAGS) -DPLUGIN_BUILD
 libmech_gssapi_la_SOURCES = mech-gssapi.c
 endif
 
 if LDAP_PLUGIN
 libauthdb_ldap_la_LDFLAGS = -module -avoid-version
 libauthdb_ldap_la_LIBADD = $(LDAP_LIBS)
-libauthdb_ldap_la_CPPFLAGS = $(AM_CPPFLAGS)
+libauthdb_ldap_la_CPPFLAGS = $(AM_CPPFLAGS) -DPLUGIN_BUILD
 libauthdb_ldap_la_SOURCES = $(ldap_sources)
 endif
 
index 4f36491dba0ac84c17b4226835d070d9afa64a88..b10a947f1efc01017c7e95f18de571e309c830e3 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "common.h"
 
-#if defined(PASSDB_LDAP) || defined(USERDB_LDAP)
+#if defined(BUILTIN_LDAP) || defined(PLUGIN_BUILD)
 
 #include "network.h"
 #include "ioloop.h"
index fe61fa4f75addfb55d2605495e7ded2b5fa6d266..a2b8c8aae3fd5e275bc9bb283a774b99cd9c4119 100644 (file)
@@ -23,7 +23,7 @@
 
 #include <stdlib.h>
 
-#ifdef HAVE_GSSAPI
+#if defined(BUILTIN_GSSAPI) || defined(PLUGIN_BUILD)
 
 #ifndef HAVE___GSS_USEROK
 #  define USE_KRB5_USEROK
index 64c83dccebe104b59f875bea86b06bdafe2d85cc..e28287780f89a09559503fca845903daa59f0038 100644 (file)
@@ -3,7 +3,7 @@
 #include "common.h"
 #include "passdb.h"
 
-#ifdef PASSDB_LDAP
+#if defined(PASSDB_LDAP) && (defined(BUILTIN_LDAP) || defined(PLUGIN_BUILD))
 
 #include "ioloop.h"
 #include "hash.h"
index 02dc4eea95845084ebd1ef44aaa88df11aab33aa..9c41fde800999075f6bf050aab98b822a7450844 100644 (file)
@@ -3,7 +3,7 @@
 #include "common.h"
 #include "userdb.h"
 
-#ifdef USERDB_LDAP
+#if defined(USERDB_LDAP) && (defined(BUILTIN_LDAP) || defined(PLUGIN_BUILD))
 
 #include "hash.h"
 #include "str.h"