| 1 | diff -u -r ../php-7.2.3/ext/opcache/config.m4 ./ext/opcache/config.m4 |
| 2 | --- ../php-7.2.3/ext/opcache/config.m4 2018-02-27 16:33:06.000000000 +0000 |
| 3 | +++ ./ext/opcache/config.m4 2018-03-10 23:38:51.259947633 +0000 |
| 4 | @@ -147,7 +147,9 @@ |
| 5 | } |
| 6 | ],dnl |
| 7 | AC_DEFINE(HAVE_SHM_MMAP_ANON, 1, [Define if you have mmap(MAP_ANON) SHM support]) |
| 8 | - msg=yes,msg=no,msg=no) |
| 9 | + msg=yes,msg=no, |
| 10 | + AC_DEFINE(HAVE_SHM_MMAP_ANON, 1, [Define if you have mmap(MAP_ANON) SHM support]) |
| 11 | + msg=yes) |
| 12 | AC_MSG_RESULT([$msg]) |
| 13 | |
| 14 | AC_MSG_CHECKING(for mmap() using /dev/zero shared memory support) |
| 15 | @@ -358,7 +360,15 @@ |
| 16 | flock_type=linux |
| 17 | AC_DEFINE([HAVE_FLOCK_LINUX], [], [Struct flock is Linux-type]) |
| 18 | AC_MSG_RESULT("yes") |
| 19 | -], AC_MSG_RESULT("no") ) |
| 20 | +], [ |
| 21 | + AC_MSG_RESULT("no") |
| 22 | +], [ |
| 23 | + dnl cross-compiling; assume Linux |
| 24 | + flock_type=linux |
| 25 | + AC_DEFINE([HAVE_FLOCK_LINUX], [], [Struct flock is Linux-type]) |
| 26 | + AC_MSG_RESULT("yes") |
| 27 | +]) |
| 28 | + |
| 29 | |
| 30 | AC_MSG_CHECKING("whether flock struct is BSD ordered") |
| 31 | AC_TRY_RUN([ |
| 32 | @@ -374,7 +384,13 @@ |
| 33 | flock_type=bsd |
| 34 | AC_DEFINE([HAVE_FLOCK_BSD], [], [Struct flock is BSD-type]) |
| 35 | AC_MSG_RESULT("yes") |
| 36 | -], AC_MSG_RESULT("no") ) |
| 37 | +], [ |
| 38 | + AC_MSG_RESULT("no") |
| 39 | +], [ |
| 40 | + dnl cross-compiling; assume Linux |
| 41 | + AC_MSG_RESULT("no") |
| 42 | +]) |
| 43 | + |
| 44 | |
| 45 | if test "$flock_type" = "unknown"; then |
| 46 | AC_MSG_ERROR([Don't know how to define struct flock on this system[,] set --enable-opcache=no]) |
| 47 | @@ -417,6 +433,9 @@ |
| 48 | Optimizer/zend_dump.c, |
| 49 | shared,,-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1,,yes) |
| 50 | |
| 51 | + OPCACHE_SHARED_LIBADD=-lpcre |
| 52 | + PHP_SUBST(OPCACHE_SHARED_LIBADD) |
| 53 | + |
| 54 | PHP_ADD_BUILD_DIR([$ext_builddir/Optimizer], 1) |
| 55 | PHP_ADD_EXTENSION_DEP(opcache, pcre) |
| 56 | fi |