Topic: PHP 5.5.38 different version of PCRE engine

Hello,

it seems the that PHP 5.5.38 has been compiled with different version of PCRE engine (Perl Compatible Regular Expressions) in Enterprise Linux 7 and Enterprise Linux 6 repository. I found out this when i installed PHP 5.5.38 on Centos 6.5 and Centos 7. And look into PHP info - it shows different version of PCRE engine on Centos 6.5 (8.38 2015-11-23) and Centos 7 (8.32 2012-11-30). According  php-config  --configure-options PHP binaries in Enterprise Linux 7 repo has been compiled with flag --with-pcre-regex=/usr which allows to use external PCRE library. This can cause some small issues as the bundled version of PCRE in PHP (7.0.3 / 5.6.18 / 5.5.32) is 8.38. At this moment i know that the different version can affect for example this code:

echo preg_replace('/[^[:print:]]/u', '', 'ČEZ');

In the PHP compiled with PCRE 8.38 it prints "ČEZ", but in the PHP with 8.32 just "EZ".

Re: PHP 5.5.38 different version of PCRE engine

I always try to use system libraries when possible.

Indeed, in EL-6 I use the bundle copy, as system one is far too old.
But as EL-7 version is recent enough, I use it there.

So, please file a bug against "pcre"

Notice:
- PHP 5.5 is now EOL
- it is not possible to change this build option, as it will break half of the stack (mass rebuild doesn't seems to make sense)

Laptop:  Fedora 38 + rpmfusion + remi (SCL only)
x86_64 builder: Fedora 39 + rpmfusion + remi-test
aarch64 builder: RHEL 9 with EPEL
Hosting Server: CentOS 8 Stream with EPEL, rpmfusion, remi

Re: PHP 5.5.38 different version of PCRE engine

Notice also affects official RHEL packages (tested in 7.3)

$ php -r "var_dump(PHP_VERSION, preg_replace('/[^[:print:]]/u', '', 'ČEZ'));"
string(6) "5.4.16"
string(2) "EZ"

$ scl enable rh-php56 bash
$ php -r "var_dump(PHP_VERSION, preg_replace('/[^[:print:]]/u', '', 'ČEZ'));"
string(6) "5.6.25"
string(2) "EZ"

$ scl enable rh-php70 bash
$ php -r "var_dump(PHP_VERSION, preg_replace('/[^[:print:]]/u', '', 'ČEZ'));"
string(6) "7.0.10"
string(2) "EZ"
Laptop:  Fedora 38 + rpmfusion + remi (SCL only)
x86_64 builder: Fedora 39 + rpmfusion + remi-test
aarch64 builder: RHEL 9 with EPEL
Hosting Server: CentOS 8 Stream with EPEL, rpmfusion, remi

Re: PHP 5.5.38 different version of PCRE engine

See RHEL bug #1400267

Laptop:  Fedora 38 + rpmfusion + remi (SCL only)
x86_64 builder: Fedora 39 + rpmfusion + remi-test
aarch64 builder: RHEL 9 with EPEL
Hosting Server: CentOS 8 Stream with EPEL, rpmfusion, remi