Skip to content

Commit 26f98ec

Browse files
committed
Sync the changes to ext/filter with 7.4, now that it works.
- Removed --with-pcre-dir - The filter extension can now be built as shared on Unix with ./configure
1 parent 6bbb18a commit 26f98ec

File tree

4 files changed

+13
-39
lines changed

4 files changed

+13
-39
lines changed

NEWS

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,11 @@ PHP NEWS
2525
- FFI:
2626
. Added FFI extension. (Dmitry)
2727

28+
- Filter:
29+
. The filter extension no longer have the --with-pcre-dir on Unix builds,
30+
allowing the extension to be once more compiled as shared using
31+
./configure. (Kalle)
32+
2833
- FPM:
2934
. Implemented FR #72510 (systemd service should be hardened). (Craig Andrews)
3035

UPGRADING

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -251,6 +251,10 @@ PHP 7.4 UPGRADE NOTES
251251
. imagescale() now supports aspect ratio preserving scaling to a fixed height
252252
by passing -1 as $new_width.
253253

254+
- Filter:
255+
. The filter extension no longer exposes --with-pcre-dir for Unix builds and
256+
can now reliably be built as shared when using ./configure once more.
257+
254258
- Hash:
255259
. The hash extension cannot be disabled anymore and is always an integral
256260
part of any PHP build, similar to the date extension.

UPGRADING.INTERNALS

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,10 @@ PHP 7.4 INTERNALS UPGRADE NOTES
190190

191191
a. Abstract
192192
- The hash extension is now always available, meaning the --enable-hash
193-
configure argument has been removed.
193+
configure argument has been removed.
194+
- The filter extension no longer exposes the --with-pcre-dir configure
195+
argument and therefore allows shared builds with ./configure for Unix
196+
builds.
194197

195198
b. Unix build system changes
196199
- configure --help now also outputs --program-suffix and --program-prefix

ext/filter/config.m4

Lines changed: 0 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -6,45 +6,7 @@ PHP_ARG_ENABLE([filter],
66
[Disable input filter support])],
77
[yes])
88

9-
PHP_ARG_WITH([pcre-dir],
10-
[pcre install prefix],
11-
[AS_HELP_STRING([--with-pcre-dir],
12-
[FILTER: pcre install prefix])],
13-
[no],
14-
[no])
15-
169
if test "$PHP_FILTER" != "no"; then
17-
18-
dnl Check if configure is the PHP core configure
19-
if test -n "$PHP_VERSION"; then
20-
dnl This extension can not be build as shared when in PHP core
21-
ext_shared=no
22-
else
23-
dnl This is PECL build, check if bundled PCRE library is used
24-
old_CPPFLAGS=$CPPFLAGS
25-
CPPFLAGS=$INCLUDES
26-
AC_EGREP_CPP(yes,[
27-
#include <main/php_config.h>
28-
#if defined(HAVE_BUNDLED_PCRE) && !defined(COMPILE_DL_PCRE)
29-
yes
30-
#endif
31-
],[
32-
PHP_PCRE_REGEX=yes
33-
],[
34-
AC_EGREP_CPP(yes,[
35-
#include <main/php_config.h>
36-
#if defined(HAVE_PCRE) && !defined(COMPILE_DL_PCRE)
37-
yes
38-
#endif
39-
],[
40-
PHP_PCRE_REGEX=pecl
41-
],[
42-
PHP_PCRE_REGEX=no
43-
])
44-
])
45-
CPPFLAGS=$old_CPPFLAGS
46-
fi
47-
4810
PHP_NEW_EXTENSION(filter, filter.c sanitizing_filters.c logical_filters.c callback_filter.c, $ext_shared,, -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1)
4911
PHP_SUBST(FILTER_SHARED_LIBADD)
5012

0 commit comments

Comments
 (0)