./devel/pcre2, Perl Compatible Regular Expressions library (major version 2)

[ CVSweb ] [ Homepage ] [ RSS ] [ Required by ] [ Add to tracker ]

Branch: CURRENT, Version: 10.35nb1, Package name: pcre2-10.35nb1, Maintainer: pkgsrc-users

PCRE2 is a re-working of the original PCRE library to provide an entirely new

PCRE2 is written in C, and it has its own API. There are three sets of
functions, one for the 8-bit library, which processes strings of bytes, one for
the 16-bit library, which processes strings of 16-bit values, and one for the
32-bit library, which processes strings of 32-bit values. There are no C++

Required to build:

Package options: pcre2-jit

Master sites:

SHA1: 2e5ee2dd397fa8c3ce9aed1a986e51d66a88bdb0
RMD160: fdfdf74eec41107c77eecc071eb153efabd59605
Filesize: 1684.779 KB

Version history: (Expand)

CVS history: (Expand)

   2020-05-28 09:53:05 by Thomas Klausner | Files touched by this commit (3) | Package updated
Log message:
pcre2: update to 10.35nb1.

Fix cleanup alloc_chunk() in sljitProtExec for NetBSD using upstream
   2020-05-19 16:18:49 by Nia Alarie | Files touched by this commit (3) | Package updated
Log message:
pcre2: Update to 10.35

Version 10.35 09-May-2020

1. Use PCRE2_MATCH_EMPTY flag to detect empty matches in JIT.

2. Fix ARMv5 JIT improper handling of labels right after a constant pool.

3. A JIT bug is fixed which allowed to read the fields of the compiled
pattern before its existence is checked.

4. Back in the PCRE1 day, capturing groups that contained recursive back
references to themselves were made atomic (version 8.01, change 18) because
after the end a repeated group, the captured substrings had their values from
the final repetition, not from an earlier repetition that might be the
destination of a backtrack. This feature was documented, and was carried over
into PCRE2. However, it has now been realized that the major refactoring that
was done for 10.30 has made this atomicizing unnecessary, and it is confusing
when users are unaware of it, making some patterns appear not to be working as
expected. Capture values of recursive back references in repeated groups are
now correctly backtracked, so this unnecessary restriction has been removed.


6. Avoid some VS compiler warnings.


8. Added (?* and (?<* as synonms for (*napla: and (*naplb: to match another
regex engine. The Perl regex folks are aware of this usage and have made a note
about it.

9. When an assertion is repeated, PCRE2 used to limit the maximum repetition to
1, believing that repeating an assertion is pointless. However, if a positive
assertion contains capturing groups, repetition can be useful. In any case, an
assertion could always be wrapped in a repeated group. The only restriction
that is now imposed is that an unlimited maximum is changed to one more than
the minimum.

10. Fix *THEN verbs in lookahead assertions in JIT.


12. The JIT stack should be freed when the low-level stack allocation fails.

13. In pcre2grep, if the final line in a scanned file is output but does not
end with a newline sequence, add a newline according to the --newline setting.

14. (?(DEFINE)...) groups were not being handled correctly when checking for
the fixed length of a lookbehind assertion. Such a group within a lookbehind
should be skipped, as it does not contribute to the length of the group.
Instead, the (DEFINE) group was being processed, and if at the end of the
lookbehind, that end was not correctly recognized. Errors such as "lookbehind
assertion is not fixed length" and also "internal error: bad code value in
parsed_skip()" could result.

15. Put a limit of 1000 on recursive calls in pcre2_study() when searching
nested groups for starting code units, in order to avoid stack overflow issues.
If the limit is reached, it just gives up trying for this optimization.

16. The control verb chain list must always be restored when exiting from a
recurse function in JIT.

17. Fix a crash which occurs when the character type of an invalid UTF
character is decoded in JIT.

18. Changes in many areas of the code so that when Unicode is supported and
PCRE2_UCP is set without PCRE2_UTF, Unicode character properties are used for
upper/lower case computations on characters whose code points are greater than

19. The function for checking UTF-16 validity was returning an incorrect offset
for the start of the error when a high surrogate was not followed by a valid
low surrogate. This caused incorrect behaviour, for example when
PCRE2_MATCH_INVALID_UTF was set and a match started immediately following the
invalid high surrogate, such as /aa/ matching "\x{d800}aa".

20. If a DEFINE group immediately preceded a lookbehind assertion, the pattern
could be mis-compiled and therefore not match correctly. This is the example
that found this: /(?(DEFINE)(?<foo>bar))(?<![-a-z0-9])word/ which failed to
match "word" because the "move back" value was set to zero.

21. Following a request from a user, some extensions and tidies to the
character tables handling have been done:

  (a) The dftables auxiliary program is renamed pcre2_dftables, but it is still
  not installed for public use.

  (b) There is now a -b option for pcre2_dftables, which causes the tables to
  be written in binary. There is also a -help option.

  (c) PCRE2_CONFIG_TABLES_LENGTH is added to pcre2_config() so that an
  application that wants to save tables in binary knows how long they are.

22. Changed setting of CMAKE_MODULE_PATH in CMakeLists.txt from SET to
LIST(APPEND...) to allow a setting from the command line to be included.

23. Updated to Unicode 13.0.0.

24. CMake build now checks for secure_getenv() and strerror(). Patch by Carlo.

25. Avoid using [-1] as a suffix in pcre2test because it can provoke a compiler

26. Added tests for __attribute__((uninitialized)) to both the configure and
CMake build files, and then applied this attribute to the variable called
stack_frames_vector[] in pcre2_match(). When implemented, this disables
automatic initialization (a facility in clang), which can take time on big

27. Updated CMakeLists.txt (patches by Uwe Korn) to add support for
pcre2-config, the libpcre*.pc files, SOVERSION, VERSION and the
MACHO_*_VERSIONS settings for CMake builds.

28. Another patch to CMakeLists.txt to check for mkostemp (configure already
does). Patch by Carlo Marcelo Arenas Belon.

29. Check for the existence of memfd_create in both CMake and configure
configurations. Patch by Carlo Marcelo Arenas Belon.

30. Restrict the configuration setting for the SELinux compatible execmem
allocator (change 10.30/44) to Linux and NetBSD.
   2020-01-26 18:32:28 by Roland Illig | Files touched by this commit (981)
Log message:
all: migrate homepages from http to https

pkglint -r --network --only "migrate"

As a side-effect of migrating the homepages, pkglint also fixed a few
indentations in unrelated lines. These and the new homepages have been
checked manually.
   2019-11-26 12:23:27 by Tobias Nygren | Files touched by this commit (1)
Log message:
delete backup file
   2019-11-26 11:22:37 by Thomas Klausner | Files touched by this commit (2)
Log message:
pcre2: add upstream bug report URL
   2019-11-26 11:17:55 by Thomas Klausner | Files touched by this commit (5) | Package updated
Log message:
pcre2: update to 10.34.

Version 10.34 21-November-2019

Another release with a few enhancements as well as bugfixes and tidies. The
main new features are:

1. There is now some support for matching in invalid UTF strings.

2. Non-atomic positive lookarounds are implemented in the pcre2_match()
interpreter, but not in JIT.

3. Added two new functions: pcre2_get_match_data_size() and

4. Upgraded to Unicode 12.1.0.
   2019-09-17 12:56:03 by Niclas Rosenvik | Files touched by this commit (2)
Log message:
Remove unused master site from pcre packages

ftp.csx.cam.ac.uk doesn't seem to be up
and it is not listed as a mirror on
www.pcre.org anymore.
   2019-04-27 20:33:12 by Thomas Klausner | Files touched by this commit (3) | Package updated
Log message:
pcre2: update to 10.33.

Version 10.33-RC1 16-April-2019

Yet more bugfixes, tidies, and a few enhancements, summarized here (see
ChangeLog for the full list):

1. Callouts from pcre2_substitute() are now available.

2. The POSIX functions are now all called pcre2_regcomp() etc., with wrapper
functions that use the standard POSIX names. However, in pcre2posix.h the POSIX
names are defined as macros. This should help avoid linking with the wrong
library in some environments, while still exporting the POSIX names for
pre-existing programs that use them.

3. Some new options:

   (a) PCRE2_EXTRA_ESCAPED_CR_IS_LF makes \r behave as \n.

   (b) PCRE2_EXTRA_ALT_BSUX enables support for ECMAScript 6's \u{hh...}

   (c) PCRE2_COPY_MATCHED_SUBJECT causes a copy of a matched subject to be
       made, instead of just remembering a pointer.

4. Some new Perl features:

   (a) Perl 5.28's experimental alphabetic names for atomic groups and
       lookaround assertions, for example, (*pla:...) and (*atomic:...).

   (b) The new Perl "script run" features (*script_run:...) and
       (*atomic_script_run:...) aka (*sr:...) and (*asr:...).

   (c) When PCRE2_UTF is set, allow non-ASCII letters and decimal digits in
       capture group names.

5. --disable-percent-zt disables the use of %zu and %td in formatting strings
in pcre2test. They were already automatically disabled for VC and older C

6. Some changes related to callouts in pcre2grep:

   (a) Support for running an external program under VMS has been added, in
       addition to Windows and fork() support.

   (b) --disable-pcre2grep-callout-fork restricts the callout support in
       to the inbuilt echo facility.