Remove support for using version 1 of the PCRE library. Its use has
been discouraged by upstream for a long time, and it's in a
bugfix-only state.
Anyone who was relying on v1 in particular got a nudge to move to v2
in e6c531b808 (Makefile: make USE_LIBPCRE=YesPlease mean v2, not v1,
2018-03-11), which was first released as part of v2.18.0.
With this the LIBPCRE2 test prerequisites is redundant to PCRE. But
I'm keeping it for self-documentation purposes, and to avoid conflict
with other in-flight PCRE patches.
I'm also not changing all of our own "pcre2" names to "pcre", i.e. the
inverse of 6d4b5747f0 (grep: change internal *pcre* variable &
function names to be *pcre1*, 2017-05-25). I don't see the point, and
it makes the history/blame harder to read. Maybe if there's ever a
PCRE v3...
Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
maint
Ævar Arnfjörð Bjarmason4 years agocommitted byJunio C Hamano
# Define USE_LIBPCRE if you have and want to use libpcre. Various
# commands such as log and grep offer runtime options to use
# Perl-compatible regular expressions instead of standard or extended
# POSIX regular expressions.
#
# USE_LIBPCRE is a synonym for USE_LIBPCRE2, define USE_LIBPCRE1
# instead if you'd like to use the legacy version 1 of the PCRE
# library. Support for version 1 will likely be removed in some future
# release of Git, as upstream has all but abandoned it.
# POSIX regular expressions. Only libpcre version 2 is supported.
#
# Define LIBPCREDIR=/foo/bar if your PCRE header and library files are in
# /foo/bar/include and /foo/bar/lib directories.
#
AC_ARG_WITH(libpcre1,
AS_HELP_STRING([--with-libpcre1],[DEPRECATED]),
AC_MSG_ERROR([support for --with-libpcre1 has been removed. Use --with-libpcre2!])
)
AC_ARG_WITH(libpcre,
AS_HELP_STRING([--with-libpcre],[synonym for --with-libpcre2]),
if test "$withval" = "no"; then
@ -277,22 +278,6 @@ AS_HELP_STRING([--with-libpcre],[synonym for --with-libpcre2]),
@@ -277,22 +278,6 @@ AS_HELP_STRING([--with-libpcre],[synonym for --with-libpcre2]),
GIT_CONF_SUBST([LIBPCREDIR])
fi)
AC_ARG_WITH(libpcre1,
AS_HELP_STRING([--with-libpcre1],[support Perl-compatible regexes via libpcre1 (default is NO)])
AS_HELP_STRING([], [ARG can be also prefix for libpcre library and headers]),
if test "$withval" = "no"; then
USE_LIBPCRE1=
elif test "$withval" = "yes"; then
USE_LIBPCRE1=YesPlease
else
USE_LIBPCRE1=YesPlease
LIBPCREDIR=$withval
AC_MSG_NOTICE([Setting LIBPCREDIR to $LIBPCREDIR])
dnl USE_LIBPCRE1 can still be modified below, so don't substitute
dnl it yet.
GIT_CONF_SUBST([LIBPCREDIR])
fi)
AC_ARG_WITH(libpcre2,
AS_HELP_STRING([--with-libpcre2],[support Perl-compatible regexes via libpcre2 (default is NO)])
AS_HELP_STRING([], [ARG can be also prefix for libpcre library and headers]),
@ -300,10 +285,6 @@ AS_HELP_STRING([], [ARG can be also prefix for libpcre library and hea
@@ -300,10 +285,6 @@ AS_HELP_STRING([], [ARG can be also prefix for libpcre library and hea
AC_MSG_ERROR([Only supply one of --with-libpcre or its synonym --with-libpcre2!])
fi
if test -n "$USE_LIBPCRE1"; then
AC_MSG_ERROR([Only supply one of --with-libpcre1 or --with-libpcre2!])
@ -1104,18 +1104,6 @@ use these, and "test_set_prereq" for how to define your own.
@@ -1104,18 +1104,6 @@ use these, and "test_set_prereq" for how to define your own.
Git was compiled with support for PCRE. Wrap any tests
that use git-grep --perl-regexp or git-grep -P in these.
- LIBPCRE1
Git was compiled with PCRE v1 support via
USE_LIBPCRE1=YesPlease. Wrap any PCRE using tests that for some
reason need v1 of the PCRE library instead of v2 in these.
- LIBPCRE2
Git was compiled with PCRE v2 support via
USE_LIBPCRE2=YesPlease. Wrap any PCRE using tests that for some
reason need v2 of the PCRE library instead of v1 in these.