From: Timo Sirainen Date: Mon, 23 Feb 2026 17:33:16 +0000 (+0200) Subject: [PATCH 07/24] auth: test-auth - Run Lua unit tests even when building Lua as plugin X-Git-Tag: archive/raspbian/1%2.4.1+dfsg1-6+rpi1+deb13u4^2~19 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=cc062bae15cb38126672390fca5a4b4a5a0313b5;p=dovecot.git [PATCH 07/24] auth: test-auth - Run Lua unit tests even when building Lua as plugin Gbp-Pq: Name CVE-2026-24031-27860-4.patch --- diff --git a/src/auth/Makefile.am b/src/auth/Makefile.am index 4c6c457..1d4b5d0 100644 --- a/src/auth/Makefile.am +++ b/src/auth/Makefile.am @@ -131,6 +131,8 @@ auth_common_sources = \ $(ldap_sources) \ $(lua_sources) +test_auth_ldadd_plugins = + headers = \ auth.h \ auth-cache.h \ @@ -185,6 +187,7 @@ libauthdb_lua_la_LDFLAGS = -module -avoid-version -shared libauthdb_lua_la_LIBADD = $(LIBDOVECOT_LUA) libauthdb_lua_la_CPPFLAGS = $(AM_CPPFLAGS) -DPLUGIN_BUILD libauthdb_lua_la_SOURCES = $(lua_sources) +test_auth_ldadd_plugins += libauthdb_lua.la endif libauthdb_imap_la_LDFLAGS = -module -avoid-version -shared @@ -226,8 +229,8 @@ test_auth_SOURCES = \ test-mock.c \ test-main.c -test_auth_LDADD = $(LIBDOVECOT) $(auth_libs) $(AUTH_LIBS) $(LUA_LIBS) -test_auth_DEPENDENCIES = $(pkglibexec_PROGRAMS) $(LIBDOVECOT_DEPS) +test_auth_LDADD = $(test_auth_ldadd_plugins) $(LIBDOVECOT) $(LIBDOVECOT_LUA) $(auth_libs) $(AUTH_LIBS) $(LUA_LIBS) +test_auth_DEPENDENCIES = $(test_auth_ldadd_plugins) $(pkglibexec_PROGRAMS) $(LIBDOVECOT_DEPS) test_mech_SOURCES = \ $(auth_common_sources) \ diff --git a/src/auth/test-lua.c b/src/auth/test-lua.c index f64f47e..1b53d72 100644 --- a/src/auth/test-lua.c +++ b/src/auth/test-lua.c @@ -2,7 +2,7 @@ #include "test-auth.h" -#ifdef BUILTIN_LUA +#ifdef HAVE_LUA #include "istream.h" #include "auth-settings.h" #include "auth-request.h" diff --git a/src/auth/test-main.c b/src/auth/test-main.c index d82f44f..cb05fda 100644 --- a/src/auth/test-main.c +++ b/src/auth/test-main.c @@ -22,7 +22,7 @@ int main(int argc, char *argv[]) TEST_NAMED(test_auth_request_var_expand) TEST_NAMED(test_auth_request_fields) TEST_NAMED(test_username_filter) -#if defined(BUILTIN_LUA) +#if defined(HAVE_LUA) TEST_NAMED(test_db_lua) #endif { NULL, NULL }