diff --git a/configure b/configure index fd679bfa3..db3dd47e7 100755 --- a/configure +++ b/configure @@ -6881,12 +6881,12 @@ if test -n "$PCRE2_CFLAGS"; then pkg_cv_PCRE2_CFLAGS="$PCRE2_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ - { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpcre2-8 >= 10.34\""; } >&5 - ($PKG_CONFIG --exists --print-errors "libpcre2-8 >= 10.34") 2>&5 + { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpcre2-8 >= 10.00\""; } >&5 + ($PKG_CONFIG --exists --print-errors "libpcre2-8 >= 10.00") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then - pkg_cv_PCRE2_CFLAGS=`$PKG_CONFIG --cflags "libpcre2-8 >= 10.34" 2>/dev/null` + pkg_cv_PCRE2_CFLAGS=`$PKG_CONFIG --cflags "libpcre2-8 >= 10.00" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes @@ -6898,12 +6898,12 @@ if test -n "$PCRE2_LIBS"; then pkg_cv_PCRE2_LIBS="$PCRE2_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ - { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpcre2-8 >= 10.34\""; } >&5 - ($PKG_CONFIG --exists --print-errors "libpcre2-8 >= 10.34") 2>&5 + { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpcre2-8 >= 10.00\""; } >&5 + ($PKG_CONFIG --exists --print-errors "libpcre2-8 >= 10.00") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then - pkg_cv_PCRE2_LIBS=`$PKG_CONFIG --libs "libpcre2-8 >= 10.34" 2>/dev/null` + pkg_cv_PCRE2_LIBS=`$PKG_CONFIG --libs "libpcre2-8 >= 10.00" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes @@ -6924,9 +6924,9 @@ else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then - PCRE2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libpcre2-8 >= 10.34" 2>&1` + PCRE2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libpcre2-8 >= 10.00" 2>&1` else - PCRE2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libpcre2-8 >= 10.34" 2>&1` + PCRE2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libpcre2-8 >= 10.00" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$PCRE2_PKG_ERRORS" >&5 @@ -6950,7 +6950,7 @@ fi if test "$has_system_pcre2" = "no"; then : -pcre2_version="10.34" +pcre2_version="10.33" { $as_echo "$as_me:${as_lineno-$LINENO}: result: extracting PCRE2 regex library" >&5 $as_echo "extracting PCRE2 regex library" >&6; } cur_dir=`pwd` @@ -6967,7 +6967,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: configuring PCRE2 regex library" >&5 $as_echo "configuring PCRE2 regex library" >&6; } cd pcre2-$pcre2_version -./configure --enable-jit --enable-shared --prefix=$cur_dir/extras/pcre2 --libdir=$PRIVATELIBDIR || exit 1 +./configure --enable-jit --enable-shared --disable-unicode --prefix=$cur_dir/extras/pcre2 --libdir=$PRIVATELIBDIR || exit 1 { $as_echo "$as_me:${as_lineno-$LINENO}: result: compiling PCRE2 regex library" >&5 $as_echo "compiling PCRE2 regex library" >&6; } $ac_cv_prog_MAKER || exit 1 diff --git a/configure.ac b/configure.ac index bded2f12f..b99241bc8 100644 --- a/configure.ac +++ b/configure.ac @@ -537,12 +537,12 @@ export PATH_SEPARATOR dnl Use system pcre2 when available, unless --without-system-pcre2. has_system_pcre2="no" AS_IF([test "x$with_system_pcre2" = "xyes"],[ -PKG_CHECK_MODULES([PCRE2], libpcre2-8 >= 10.34,[has_system_pcre2=yes +PKG_CHECK_MODULES([PCRE2], libpcre2-8 >= 10.00,[has_system_pcre2=yes AS_IF([test "x$PRIVATELIBDIR" != "x"], [rm -f "$PRIVATELIBDIR/"libpcre2*])],[has_system_pcre2=no])]) AS_IF([test "$has_system_pcre2" = "no"], [ dnl REMEMBER TO CHANGE WITH A NEW PCRE2 RELEASE! -pcre2_version="10.34" +pcre2_version="10.33" AC_MSG_RESULT(extracting PCRE2 regex library) cur_dir=`pwd` cd extras @@ -559,7 +559,7 @@ else fi AC_MSG_RESULT(configuring PCRE2 regex library) cd pcre2-$pcre2_version -./configure --enable-jit --enable-shared --prefix=$cur_dir/extras/pcre2 --libdir=$PRIVATELIBDIR || exit 1 +./configure --enable-jit --enable-shared --disable-unicode --prefix=$cur_dir/extras/pcre2 --libdir=$PRIVATELIBDIR || exit 1 AC_MSG_RESULT(compiling PCRE2 regex library) $ac_cv_prog_MAKER || exit 1 AC_MSG_RESULT(installing PCRE2 regex library) diff --git a/extras/pcre2.tar.gz b/extras/pcre2.tar.gz index 244657533..3d7de9786 100644 Binary files a/extras/pcre2.tar.gz and b/extras/pcre2.tar.gz differ diff --git a/src/match.c b/src/match.c index ca255b9d9..ccc1c39f9 100644 --- a/src/match.c +++ b/src/match.c @@ -405,7 +405,7 @@ Match *unreal_create_match(MatchType type, char *str, char **error) int options = 0; char buf2[512]; - options = PCRE2_CASELESS|PCRE2_MATCH_INVALID_UTF; + options = PCRE2_CASELESS|PCRE2_NEVER_UTF|PCRE2_NEVER_UCP; m->ext.pcre2_expr = pcre2_compile(str, PCRE2_ZERO_TERMINATED, options, &errorcode, &erroroffset, NULL); if (m->ext.pcre2_expr == NULL)