summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemi Collet <remi@remirepo.net>2019-10-10 12:01:36 +0200
committerRemi Collet <remi@remirepo.net>2019-10-10 12:01:36 +0200
commit67aed2d0ea6eeb7ca10cbd0bcdfd2ad394d6cc5d (patch)
tree28db723d5e7ed4329c1090981aed1a61cd113bec
parent57fd20580655c6262f44d4ab84a7de87d0e91fb4 (diff)
fix librt issue on F31 using upstream patch
-rw-r--r--e1362b3cf0021c1c8492594da08b7a017b3585ba.patch53
-rw-r--r--php.spec7
2 files changed, 59 insertions, 1 deletions
diff --git a/e1362b3cf0021c1c8492594da08b7a017b3585ba.patch b/e1362b3cf0021c1c8492594da08b7a017b3585ba.patch
new file mode 100644
index 0000000..3fd99a8
--- /dev/null
+++ b/e1362b3cf0021c1c8492594da08b7a017b3585ba.patch
@@ -0,0 +1,53 @@
+From e1362b3cf0021c1c8492594da08b7a017b3585ba Mon Sep 17 00:00:00 2001
+From: Remi Collet <remi@remirepo.net>
+Date: Mon, 7 Oct 2019 16:31:09 +0200
+Subject: [PATCH] add librt for opcache
+
+---
+ ext/opcache/config.m4 | 14 ++++++++++++--
+ 1 file changed, 12 insertions(+), 2 deletions(-)
+
+diff --git a/ext/opcache/config.m4 b/ext/opcache/config.m4
+index a388dd787b67..6c40cafc1c39 100644
+--- a/ext/opcache/config.m4
++++ b/ext/opcache/config.m4
+@@ -13,6 +13,9 @@ PHP_ARG_ENABLE([huge-code-pages],
+
+ if test "$PHP_OPCACHE" != "no"; then
+
++ dnl Always build as shared extension
++ ext_shared=yes
++
+ if test "$PHP_HUGE_CODE_PAGES" = "yes"; then
+ AC_DEFINE(HAVE_HUGE_CODE_PAGES, 1, [Define to enable copying PHP CODE pages into HUGE PAGES (experimental)])
+ fi
+@@ -141,6 +144,7 @@ int main() {
+ msg=yes],[msg=no],[msg=no])
+ AC_MSG_RESULT([$msg])
+
++ PHP_CHECK_FUNC_LIB(shm_open, rt)
+ AC_MSG_CHECKING(for mmap() using shm_open() shared memory support)
+ AC_RUN_IFELSE([AC_LANG_SOURCE([[
+ #include <sys/types.h>
+@@ -207,8 +211,13 @@ int main() {
+ }
+ ]])],[dnl
+ AC_DEFINE(HAVE_SHM_MMAP_POSIX, 1, [Define if you have POSIX mmap() SHM support])
+- msg=yes],[msg=no],[msg=no])
+- AC_MSG_RESULT([$msg])
++ AC_MSG_RESULT([yes])
++ PHP_CHECK_LIBRARY(rt, shm_unlink, [PHP_ADD_LIBRARY(rt,1,OPCACHE_SHARED_LIBADD)])
++ ],[
++ AC_MSG_RESULT([no])
++ ],[
++ AC_MSG_RESULT([no])
++ ])
+
+ PHP_NEW_EXTENSION(opcache,
+ ZendAccelerator.c \
+@@ -250,4 +259,5 @@ int main() {
+
+ PHP_ADD_BUILD_DIR([$ext_builddir/Optimizer], 1)
+ PHP_ADD_EXTENSION_DEP(opcache, pcre)
++ PHP_SUBST(OPCACHE_SHARED_LIBADD)
+ fi
diff --git a/php.spec b/php.spec
index 4f11258..ee0f513 100644
--- a/php.spec
+++ b/php.spec
@@ -108,7 +108,7 @@
Summary: PHP scripting language for creating dynamic web sites
Name: %{?scl_prefix}php
Version: %{upver}%{?lower:~%{lower}}%{?gh_date:.%{gh_date}}
-Release: 25%{?dist}
+Release: 26%{?dist}
# All files licensed under PHP version 3.01, except
# Zend is licensed under Zend
# TSRM is licensed under BSD
@@ -167,6 +167,7 @@ Patch91: php-7.2.0-oci8conf.patch
# Upstream fixes (100+)
Patch100: https://github.com/php/php-src/commit/f633c347574c0d814050b4bf2493e0cac6a5988c.patch
+Patch101: https://github.com/php/php-src/commit/e1362b3cf0021c1c8492594da08b7a017b3585ba.patch
# Security fixes (200+)
@@ -940,6 +941,7 @@ sed -e 's/php-devel/%{?scl_prefix}php-devel/' -i scripts/phpize.in
# upstream patches
%patch100 -p1 -R
+%patch101 -p1 -b .up
# security patches
@@ -1806,6 +1808,9 @@ fi
%changelog
+* Thu Oct 10 2019 Remi Collet <remi@remirepo.net> - 7.4.0~rc3-26
+- fix librt issue on F31 using upstream patch
+
* Mon Oct 7 2019 Remi Collet <remi@remirepo.net> - 7.4.0~rc3-25
- ensure all shared extensions can be loaded