More file tidies for 10.33-RC1
This commit is contained in:
parent
02ff543f9c
commit
7375089fa5
|
@ -311,7 +311,11 @@ library. They are also documented in the pcre2build man page.
|
||||||
. There is support for calling external programs during matching in the
|
. There is support for calling external programs during matching in the
|
||||||
pcre2grep command, using PCRE2's callout facility with string arguments. This
|
pcre2grep command, using PCRE2's callout facility with string arguments. This
|
||||||
support can be disabled by adding --disable-pcre2grep-callout to the
|
support can be disabled by adding --disable-pcre2grep-callout to the
|
||||||
"configure" command.
|
"configure" command. There are two kinds of callout: one that generates
|
||||||
|
output from inbuilt code, and another that calls an external program. The
|
||||||
|
latter has special support for Windows and VMS; otherwise it assumes the
|
||||||
|
existence of the fork() function. This facility can be disabled by adding
|
||||||
|
--disable-pcre2grep-callout-fork to the "configure" command.
|
||||||
|
|
||||||
. The pcre2grep program currently supports only 8-bit data files, and so
|
. The pcre2grep program currently supports only 8-bit data files, and so
|
||||||
requires the 8-bit PCRE2 library. It is possible to compile pcre2grep to use
|
requires the 8-bit PCRE2 library. It is possible to compile pcre2grep to use
|
||||||
|
@ -886,4 +890,4 @@ The distribution should contain the files listed below.
|
||||||
Philip Hazel
|
Philip Hazel
|
||||||
Email local part: ph10
|
Email local part: ph10
|
||||||
Email domain: cam.ac.uk
|
Email domain: cam.ac.uk
|
||||||
Last updated: 29 January 2019
|
Last updated: 03 March 2019
|
||||||
|
|
|
@ -376,12 +376,15 @@ environment.
|
||||||
</P>
|
</P>
|
||||||
<br><a name="SEC14" href="#TOC1">PCRE2GREP SUPPORT FOR EXTERNAL SCRIPTS</a><br>
|
<br><a name="SEC14" href="#TOC1">PCRE2GREP SUPPORT FOR EXTERNAL SCRIPTS</a><br>
|
||||||
<P>
|
<P>
|
||||||
By default, on non-Windows systems, <b>pcre2grep</b> supports the use of
|
By default <b>pcre2grep</b> supports the use of callouts with string arguments
|
||||||
callouts with string arguments within the patterns it is matching, in order to
|
within the patterns it is matching. There are two kinds: one that generates
|
||||||
run external scripts. For details, see the
|
output using local code, and another that calls an external program or script.
|
||||||
|
If --disable-pcre2grep-callout-fork is added to the <b>configure</b> command,
|
||||||
|
only the first kind of callout is supported; if --disable-pcre2grep-callout is
|
||||||
|
used, all callouts are completely ignored. For more details of <b>pcre2grep</b>
|
||||||
|
callouts, see the
|
||||||
<a href="pcre2grep.html"><b>pcre2grep</b></a>
|
<a href="pcre2grep.html"><b>pcre2grep</b></a>
|
||||||
documentation. This support can be disabled by adding
|
documentation.
|
||||||
--disable-pcre2grep-callout to the <b>configure</b> command.
|
|
||||||
</P>
|
</P>
|
||||||
<br><a name="SEC15" href="#TOC1">PCRE2GREP OPTIONS FOR COMPRESSED FILE SUPPORT</a><br>
|
<br><a name="SEC15" href="#TOC1">PCRE2GREP OPTIONS FOR COMPRESSED FILE SUPPORT</a><br>
|
||||||
<P>
|
<P>
|
||||||
|
@ -589,9 +592,9 @@ Cambridge, England.
|
||||||
</P>
|
</P>
|
||||||
<br><a name="SEC26" href="#TOC1">REVISION</a><br>
|
<br><a name="SEC26" href="#TOC1">REVISION</a><br>
|
||||||
<P>
|
<P>
|
||||||
Last updated: 15 November 2018
|
Last updated: 03 March 2019
|
||||||
<br>
|
<br>
|
||||||
Copyright © 1997-2018 University of Cambridge.
|
Copyright © 1997-2019 University of Cambridge.
|
||||||
<br>
|
<br>
|
||||||
<p>
|
<p>
|
||||||
Return to the <a href="index.html">PCRE2 index page</a>.
|
Return to the <a href="index.html">PCRE2 index page</a>.
|
||||||
|
|
123
doc/pcre2.txt
123
doc/pcre2.txt
|
@ -4027,45 +4027,48 @@ USING EBCDIC CODE
|
||||||
|
|
||||||
PCRE2GREP SUPPORT FOR EXTERNAL SCRIPTS
|
PCRE2GREP SUPPORT FOR EXTERNAL SCRIPTS
|
||||||
|
|
||||||
By default, on non-Windows systems, pcre2grep supports the use of call-
|
By default pcre2grep supports the use of callouts with string arguments
|
||||||
outs with string arguments within the patterns it is matching, in order
|
within the patterns it is matching. There are two kinds: one that gen-
|
||||||
to run external scripts. For details, see the pcre2grep documentation.
|
erates output using local code, and another that calls an external pro-
|
||||||
This support can be disabled by adding --disable-pcre2grep-callout to
|
gram or script. If --disable-pcre2grep-callout-fork is added to the
|
||||||
the configure command.
|
configure command, only the first kind of callout is supported; if
|
||||||
|
--disable-pcre2grep-callout is used, all callouts are completely
|
||||||
|
ignored. For more details of pcre2grep callouts, see the pcre2grep doc-
|
||||||
|
umentation.
|
||||||
|
|
||||||
|
|
||||||
PCRE2GREP OPTIONS FOR COMPRESSED FILE SUPPORT
|
PCRE2GREP OPTIONS FOR COMPRESSED FILE SUPPORT
|
||||||
|
|
||||||
By default, pcre2grep reads all files as plain text. You can build it
|
By default, pcre2grep reads all files as plain text. You can build it
|
||||||
so that it recognizes files whose names end in .gz or .bz2, and reads
|
so that it recognizes files whose names end in .gz or .bz2, and reads
|
||||||
them with libz or libbz2, respectively, by adding one or both of
|
them with libz or libbz2, respectively, by adding one or both of
|
||||||
|
|
||||||
--enable-pcre2grep-libz
|
--enable-pcre2grep-libz
|
||||||
--enable-pcre2grep-libbz2
|
--enable-pcre2grep-libbz2
|
||||||
|
|
||||||
to the configure command. These options naturally require that the rel-
|
to the configure command. These options naturally require that the rel-
|
||||||
evant libraries are installed on your system. Configuration will fail
|
evant libraries are installed on your system. Configuration will fail
|
||||||
if they are not.
|
if they are not.
|
||||||
|
|
||||||
|
|
||||||
PCRE2GREP BUFFER SIZE
|
PCRE2GREP BUFFER SIZE
|
||||||
|
|
||||||
pcre2grep uses an internal buffer to hold a "window" on the file it is
|
pcre2grep uses an internal buffer to hold a "window" on the file it is
|
||||||
scanning, in order to be able to output "before" and "after" lines when
|
scanning, in order to be able to output "before" and "after" lines when
|
||||||
it finds a match. The default starting size of the buffer is 20KiB. The
|
it finds a match. The default starting size of the buffer is 20KiB. The
|
||||||
buffer itself is three times this size, but because of the way it is
|
buffer itself is three times this size, but because of the way it is
|
||||||
used for holding "before" lines, the longest line that is guaranteed to
|
used for holding "before" lines, the longest line that is guaranteed to
|
||||||
be processable is the notional buffer size. If a longer line is encoun-
|
be processable is the notional buffer size. If a longer line is encoun-
|
||||||
tered, pcre2grep automatically expands the buffer, up to a specified
|
tered, pcre2grep automatically expands the buffer, up to a specified
|
||||||
maximum size, whose default is 1MiB or the starting size, whichever is
|
maximum size, whose default is 1MiB or the starting size, whichever is
|
||||||
the larger. You can change the default parameter values by adding, for
|
the larger. You can change the default parameter values by adding, for
|
||||||
example,
|
example,
|
||||||
|
|
||||||
--with-pcre2grep-bufsize=51200
|
--with-pcre2grep-bufsize=51200
|
||||||
--with-pcre2grep-max-bufsize=2097152
|
--with-pcre2grep-max-bufsize=2097152
|
||||||
|
|
||||||
to the configure command. The caller of pcre2grep can override these
|
to the configure command. The caller of pcre2grep can override these
|
||||||
values by using --buffer-size and --max-buffer-size on the command
|
values by using --buffer-size and --max-buffer-size on the command
|
||||||
line.
|
line.
|
||||||
|
|
||||||
|
|
||||||
|
@ -4076,26 +4079,26 @@ PCRE2TEST OPTION FOR LIBREADLINE SUPPORT
|
||||||
--enable-pcre2test-libreadline
|
--enable-pcre2test-libreadline
|
||||||
--enable-pcre2test-libedit
|
--enable-pcre2test-libedit
|
||||||
|
|
||||||
to the configure command, pcre2test is linked with the libreadline
|
to the configure command, pcre2test is linked with the libreadline
|
||||||
orlibedit library, respectively, and when its input is from a terminal,
|
orlibedit library, respectively, and when its input is from a terminal,
|
||||||
it reads it using the readline() function. This provides line-editing
|
it reads it using the readline() function. This provides line-editing
|
||||||
and history facilities. Note that libreadline is GPL-licensed, so if
|
and history facilities. Note that libreadline is GPL-licensed, so if
|
||||||
you distribute a binary of pcre2test linked in this way, there may be
|
you distribute a binary of pcre2test linked in this way, there may be
|
||||||
licensing issues. These can be avoided by linking instead with libedit,
|
licensing issues. These can be avoided by linking instead with libedit,
|
||||||
which has a BSD licence.
|
which has a BSD licence.
|
||||||
|
|
||||||
Setting --enable-pcre2test-libreadline causes the -lreadline option to
|
Setting --enable-pcre2test-libreadline causes the -lreadline option to
|
||||||
be added to the pcre2test build. In many operating environments with a
|
be added to the pcre2test build. In many operating environments with a
|
||||||
sytem-installed readline library this is sufficient. However, in some
|
sytem-installed readline library this is sufficient. However, in some
|
||||||
environments (e.g. if an unmodified distribution version of readline is
|
environments (e.g. if an unmodified distribution version of readline is
|
||||||
in use), some extra configuration may be necessary. The INSTALL file
|
in use), some extra configuration may be necessary. The INSTALL file
|
||||||
for libreadline says this:
|
for libreadline says this:
|
||||||
|
|
||||||
"Readline uses the termcap functions, but does not link with
|
"Readline uses the termcap functions, but does not link with
|
||||||
the termcap or curses library itself, allowing applications
|
the termcap or curses library itself, allowing applications
|
||||||
which link with readline the to choose an appropriate library."
|
which link with readline the to choose an appropriate library."
|
||||||
|
|
||||||
If your environment has not been set up so that an appropriate library
|
If your environment has not been set up so that an appropriate library
|
||||||
is automatically included, you may need to add something like
|
is automatically included, you may need to add something like
|
||||||
|
|
||||||
LIBS="-ncurses"
|
LIBS="-ncurses"
|
||||||
|
@ -4109,7 +4112,7 @@ INCLUDING DEBUGGING CODE
|
||||||
|
|
||||||
--enable-debug
|
--enable-debug
|
||||||
|
|
||||||
to the configure command, additional debugging code is included in the
|
to the configure command, additional debugging code is included in the
|
||||||
build. This feature is intended for use by the PCRE2 maintainers.
|
build. This feature is intended for use by the PCRE2 maintainers.
|
||||||
|
|
||||||
|
|
||||||
|
@ -4119,15 +4122,15 @@ DEBUGGING WITH VALGRIND SUPPORT
|
||||||
|
|
||||||
--enable-valgrind
|
--enable-valgrind
|
||||||
|
|
||||||
to the configure command, PCRE2 will use valgrind annotations to mark
|
to the configure command, PCRE2 will use valgrind annotations to mark
|
||||||
certain memory regions as unaddressable. This allows it to detect
|
certain memory regions as unaddressable. This allows it to detect
|
||||||
invalid memory accesses, and is mostly useful for debugging PCRE2
|
invalid memory accesses, and is mostly useful for debugging PCRE2
|
||||||
itself.
|
itself.
|
||||||
|
|
||||||
|
|
||||||
CODE COVERAGE REPORTING
|
CODE COVERAGE REPORTING
|
||||||
|
|
||||||
If your C compiler is gcc, you can build a version of PCRE2 that can
|
If your C compiler is gcc, you can build a version of PCRE2 that can
|
||||||
generate a code coverage report for its test suite. To enable this, you
|
generate a code coverage report for its test suite. To enable this, you
|
||||||
must install lcov version 1.6 or above. Then specify
|
must install lcov version 1.6 or above. Then specify
|
||||||
|
|
||||||
|
@ -4136,20 +4139,20 @@ CODE COVERAGE REPORTING
|
||||||
to the configure command and build PCRE2 in the usual way.
|
to the configure command and build PCRE2 in the usual way.
|
||||||
|
|
||||||
Note that using ccache (a caching C compiler) is incompatible with code
|
Note that using ccache (a caching C compiler) is incompatible with code
|
||||||
coverage reporting. If you have configured ccache to run automatically
|
coverage reporting. If you have configured ccache to run automatically
|
||||||
on your system, you must set the environment variable
|
on your system, you must set the environment variable
|
||||||
|
|
||||||
CCACHE_DISABLE=1
|
CCACHE_DISABLE=1
|
||||||
|
|
||||||
before running make to build PCRE2, so that ccache is not used.
|
before running make to build PCRE2, so that ccache is not used.
|
||||||
|
|
||||||
When --enable-coverage is used, the following addition targets are
|
When --enable-coverage is used, the following addition targets are
|
||||||
added to the Makefile:
|
added to the Makefile:
|
||||||
|
|
||||||
make coverage
|
make coverage
|
||||||
|
|
||||||
This creates a fresh coverage report for the PCRE2 test suite. It is
|
This creates a fresh coverage report for the PCRE2 test suite. It is
|
||||||
equivalent to running "make coverage-reset", "make coverage-baseline",
|
equivalent to running "make coverage-reset", "make coverage-baseline",
|
||||||
"make check", and then "make coverage-report".
|
"make check", and then "make coverage-report".
|
||||||
|
|
||||||
make coverage-reset
|
make coverage-reset
|
||||||
|
@ -4166,28 +4169,28 @@ CODE COVERAGE REPORTING
|
||||||
|
|
||||||
make coverage-clean-report
|
make coverage-clean-report
|
||||||
|
|
||||||
This removes the generated coverage report without cleaning the cover-
|
This removes the generated coverage report without cleaning the cover-
|
||||||
age data itself.
|
age data itself.
|
||||||
|
|
||||||
make coverage-clean-data
|
make coverage-clean-data
|
||||||
|
|
||||||
This removes the captured coverage data without removing the coverage
|
This removes the captured coverage data without removing the coverage
|
||||||
files created at compile time (*.gcno).
|
files created at compile time (*.gcno).
|
||||||
|
|
||||||
make coverage-clean
|
make coverage-clean
|
||||||
|
|
||||||
This cleans all coverage data including the generated coverage report.
|
This cleans all coverage data including the generated coverage report.
|
||||||
For more information about code coverage, see the gcov and lcov docu-
|
For more information about code coverage, see the gcov and lcov docu-
|
||||||
mentation.
|
mentation.
|
||||||
|
|
||||||
|
|
||||||
DISABLING THE Z AND T FORMATTING MODIFIERS
|
DISABLING THE Z AND T FORMATTING MODIFIERS
|
||||||
|
|
||||||
The C99 standard defines formatting modifiers z and t for size_t and
|
The C99 standard defines formatting modifiers z and t for size_t and
|
||||||
ptrdiff_t values, respectively. By default, PCRE2 uses these modifiers
|
ptrdiff_t values, respectively. By default, PCRE2 uses these modifiers
|
||||||
in environments other than Microsoft Visual Studio when __STDC_VER-
|
in environments other than Microsoft Visual Studio when __STDC_VER-
|
||||||
SION__ is defined and has a value greater than or equal to 199901L
|
SION__ is defined and has a value greater than or equal to 199901L
|
||||||
(indicating C99). However, there is at least one environment that
|
(indicating C99). However, there is at least one environment that
|
||||||
claims to be C99 but does not support these modifiers. If
|
claims to be C99 but does not support these modifiers. If
|
||||||
|
|
||||||
--disable-percent-zt
|
--disable-percent-zt
|
||||||
|
@ -4198,39 +4201,39 @@ DISABLING THE Z AND T FORMATTING MODIFIERS
|
||||||
|
|
||||||
SUPPORT FOR FUZZERS
|
SUPPORT FOR FUZZERS
|
||||||
|
|
||||||
There is a special option for use by people who want to run fuzzing
|
There is a special option for use by people who want to run fuzzing
|
||||||
tests on PCRE2:
|
tests on PCRE2:
|
||||||
|
|
||||||
--enable-fuzz-support
|
--enable-fuzz-support
|
||||||
|
|
||||||
At present this applies only to the 8-bit library. If set, it causes an
|
At present this applies only to the 8-bit library. If set, it causes an
|
||||||
extra library called libpcre2-fuzzsupport.a to be built, but not
|
extra library called libpcre2-fuzzsupport.a to be built, but not
|
||||||
installed. This contains a single function called LLVMFuzzerTestOneIn-
|
installed. This contains a single function called LLVMFuzzerTestOneIn-
|
||||||
put() whose arguments are a pointer to a string and the length of the
|
put() whose arguments are a pointer to a string and the length of the
|
||||||
string. When called, this function tries to compile the string as a
|
string. When called, this function tries to compile the string as a
|
||||||
pattern, and if that succeeds, to match it. This is done both with no
|
pattern, and if that succeeds, to match it. This is done both with no
|
||||||
options and with some random options bits that are generated from the
|
options and with some random options bits that are generated from the
|
||||||
string.
|
string.
|
||||||
|
|
||||||
Setting --enable-fuzz-support also causes a binary called pcre2fuz-
|
Setting --enable-fuzz-support also causes a binary called pcre2fuz-
|
||||||
zcheck to be created. This is normally run under valgrind or used when
|
zcheck to be created. This is normally run under valgrind or used when
|
||||||
PCRE2 is compiled with address sanitizing enabled. It calls the fuzzing
|
PCRE2 is compiled with address sanitizing enabled. It calls the fuzzing
|
||||||
function and outputs information about what it is doing. The input
|
function and outputs information about what it is doing. The input
|
||||||
strings are specified by arguments: if an argument starts with "=" the
|
strings are specified by arguments: if an argument starts with "=" the
|
||||||
rest of it is a literal input string. Otherwise, it is assumed to be a
|
rest of it is a literal input string. Otherwise, it is assumed to be a
|
||||||
file name, and the contents of the file are the test string.
|
file name, and the contents of the file are the test string.
|
||||||
|
|
||||||
|
|
||||||
OBSOLETE OPTION
|
OBSOLETE OPTION
|
||||||
|
|
||||||
In versions of PCRE2 prior to 10.30, there were two ways of handling
|
In versions of PCRE2 prior to 10.30, there were two ways of handling
|
||||||
backtracking in the pcre2_match() function. The default was to use the
|
backtracking in the pcre2_match() function. The default was to use the
|
||||||
system stack, but if
|
system stack, but if
|
||||||
|
|
||||||
--disable-stack-for-recursion
|
--disable-stack-for-recursion
|
||||||
|
|
||||||
was set, memory on the heap was used. From release 10.30 onwards this
|
was set, memory on the heap was used. From release 10.30 onwards this
|
||||||
has changed (the stack is no longer used) and this option now does
|
has changed (the stack is no longer used) and this option now does
|
||||||
nothing except give a warning.
|
nothing except give a warning.
|
||||||
|
|
||||||
|
|
||||||
|
@ -4248,8 +4251,8 @@ AUTHOR
|
||||||
|
|
||||||
REVISION
|
REVISION
|
||||||
|
|
||||||
Last updated: 15 November 2018
|
Last updated: 03 March 2019
|
||||||
Copyright (c) 1997-2018 University of Cambridge.
|
Copyright (c) 1997-2019 University of Cambridge.
|
||||||
------------------------------------------------------------------------------
|
------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -44,7 +44,7 @@ POSSIBILITY OF SUCH DAMAGE.
|
||||||
#define PCRE2_MAJOR 10
|
#define PCRE2_MAJOR 10
|
||||||
#define PCRE2_MINOR 33
|
#define PCRE2_MINOR 33
|
||||||
#define PCRE2_PRERELEASE -RC1
|
#define PCRE2_PRERELEASE -RC1
|
||||||
#define PCRE2_DATE 2018-09-14
|
#define PCRE2_DATE 2019-03-03
|
||||||
|
|
||||||
/* When an application links to a PCRE DLL in Windows, the symbols that are
|
/* When an application links to a PCRE DLL in Windows, the symbols that are
|
||||||
imported have to be identified as such. When building PCRE2, the appropriate
|
imported have to be identified as such. When building PCRE2, the appropriate
|
||||||
|
@ -150,6 +150,7 @@ D is inspected during pcre2_dfa_match() execution
|
||||||
#define PCRE2_EXTRA_MATCH_WORD 0x00000004u /* C */
|
#define PCRE2_EXTRA_MATCH_WORD 0x00000004u /* C */
|
||||||
#define PCRE2_EXTRA_MATCH_LINE 0x00000008u /* C */
|
#define PCRE2_EXTRA_MATCH_LINE 0x00000008u /* C */
|
||||||
#define PCRE2_EXTRA_ESCAPED_CR_IS_LF 0x00000010u /* C */
|
#define PCRE2_EXTRA_ESCAPED_CR_IS_LF 0x00000010u /* C */
|
||||||
|
#define PCRE2_EXTRA_ALT_BSUX 0x00000020u /* C */
|
||||||
|
|
||||||
/* These are for pcre2_jit_compile(). */
|
/* These are for pcre2_jit_compile(). */
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue