From: Aki Tuomi Date: Thu, 4 Sep 2025 05:46:06 +0000 (+0300) Subject: m4: Fix how pcre2_substitute_callout_block is checked X-Git-Tag: 2.4.2~424 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=24b3f138b027a23b553f4baec4d907a52b6c8cd5;p=thirdparty%2Fdovecot%2Fcore.git m4: Fix how pcre2_substitute_callout_block is checked The old way was very wrong --- diff --git a/m4/want_pcre.m4 b/m4/want_pcre.m4 index f013aaad82..692a673177 100644 --- a/m4/want_pcre.m4 +++ b/m4/want_pcre.m4 @@ -14,7 +14,12 @@ AC_DEFUN([DOVECOT_WANT_PCRE], [ AS_IF([test "$have_pcre" != "no"], [ old_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS $LIBPCRE_CFLAGS" - AC_CHECK_FUNCS([pcre2_substitute_callout_block]) + AC_CHECK_DECL([pcre2_substitute_callout_block], + AC_DEFINE(HAVE_PCRE2_SUBSTITUTE_CALLOUT_BLOCK,, + [Define if you have pcre2_substitute_callout_block]),, + [[#define PCRE2_CODE_UNIT_WIDTH 0]] + [[#include ]] + ) CFLAGS="$old_CFLAGS" AC_DEFINE(HAVE_LIBPCRE,, [Define if you have libpcre2 backed regular expressions]) ])