summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--410.patch79
-rw-r--r--php-pecl-yaf.spec15
2 files changed, 92 insertions, 2 deletions
diff --git a/410.patch b/410.patch
new file mode 100644
index 0000000..3c09d1c
--- /dev/null
+++ b/410.patch
@@ -0,0 +1,79 @@
+From 4eac86bfb340438bddfe397361f5322e85ea39f3 Mon Sep 17 00:00:00 2001
+From: Remi Collet <remi@remirepo.net>
+Date: Wed, 18 Jul 2018 11:48:57 +0200
+Subject: [PATCH] Fix for 7.3.0alpha4, make PUBLIC else
+ zend_read_static_property fails
+
+---
+ yaf_application.c | 2 +-
+ yaf_dispatcher.c | 2 +-
+ yaf_loader.c | 2 +-
+ yaf_registry.c | 2 +-
+ yaf_session.c | 2 +-
+ 5 files changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/yaf_application.c b/yaf_application.c
+index fe7ec77..451af52 100644
+--- a/yaf_application.c
++++ b/yaf_application.c
+@@ -672,7 +672,7 @@ YAF_STARTUP_FUNCTION(application) {
+ zend_declare_property_null(yaf_application_ce,
+ ZEND_STRL(YAF_APPLICATION_PROPERTY_NAME_DISPATCHER), ZEND_ACC_PROTECTED);
+ zend_declare_property_null(yaf_application_ce,
+- ZEND_STRL(YAF_APPLICATION_PROPERTY_NAME_APP), ZEND_ACC_STATIC | ZEND_ACC_PROTECTED);
++ ZEND_STRL(YAF_APPLICATION_PROPERTY_NAME_APP), ZEND_ACC_STATIC);
+ zend_declare_property_null(yaf_application_ce,
+ ZEND_STRL(YAF_APPLICATION_PROPERTY_NAME_MODULES), ZEND_ACC_PROTECTED);
+
+diff --git a/yaf_dispatcher.c b/yaf_dispatcher.c
+index f20b40a..07cf73e 100644
+--- a/yaf_dispatcher.c
++++ b/yaf_dispatcher.c
+@@ -1356,7 +1356,7 @@ YAF_STARTUP_FUNCTION(dispatcher) {
+ zend_declare_property_null(yaf_dispatcher_ce, ZEND_STRL(YAF_DISPATCHER_PROPERTY_NAME_REQUEST), ZEND_ACC_PROTECTED);
+ zend_declare_property_null(yaf_dispatcher_ce, ZEND_STRL(YAF_DISPATCHER_PROPERTY_NAME_PLUGINS), ZEND_ACC_PROTECTED);
+
+- zend_declare_property_null(yaf_dispatcher_ce, ZEND_STRL(YAF_DISPATCHER_PROPERTY_NAME_INSTANCE), ZEND_ACC_PROTECTED|ZEND_ACC_STATIC);
++ zend_declare_property_null(yaf_dispatcher_ce, ZEND_STRL(YAF_DISPATCHER_PROPERTY_NAME_INSTANCE), ZEND_ACC_STATIC);
+
+ zend_declare_property_bool(yaf_dispatcher_ce, ZEND_STRL(YAF_DISPATCHER_PROPERTY_NAME_RENDER), 1, ZEND_ACC_PROTECTED);
+ zend_declare_property_bool(yaf_dispatcher_ce, ZEND_STRL(YAF_DISPATCHER_PROPERTY_NAME_RETURN), 0, ZEND_ACC_PROTECTED);
+diff --git a/yaf_loader.c b/yaf_loader.c
+index c533bc0..822da4b 100644
+--- a/yaf_loader.c
++++ b/yaf_loader.c
+@@ -790,7 +790,7 @@ YAF_STARTUP_FUNCTION(loader) {
+
+ zend_declare_property_null(yaf_loader_ce, ZEND_STRL(YAF_LOADER_PROPERTY_NAME_LIBRARY), ZEND_ACC_PROTECTED);
+ zend_declare_property_null(yaf_loader_ce, ZEND_STRL(YAF_LOADER_PROPERTY_NAME_GLOBAL_LIB), ZEND_ACC_PROTECTED);
+- zend_declare_property_null(yaf_loader_ce, ZEND_STRL(YAF_LOADER_PROPERTY_NAME_INSTANCE), ZEND_ACC_PROTECTED|ZEND_ACC_STATIC);
++ zend_declare_property_null(yaf_loader_ce, ZEND_STRL(YAF_LOADER_PROPERTY_NAME_INSTANCE), ZEND_ACC_STATIC);
+
+ return SUCCESS;
+ }
+diff --git a/yaf_registry.c b/yaf_registry.c
+index 891b47b..f08ae36 100644
+--- a/yaf_registry.c
++++ b/yaf_registry.c
+@@ -205,7 +205,7 @@ YAF_STARTUP_FUNCTION(registry) {
+ yaf_registry_ce = zend_register_internal_class_ex(&ce, NULL);
+ yaf_registry_ce->ce_flags |= ZEND_ACC_FINAL;
+
+- zend_declare_property_null(yaf_registry_ce, ZEND_STRL(YAF_REGISTRY_PROPERTY_NAME_INSTANCE), ZEND_ACC_PROTECTED|ZEND_ACC_STATIC);
++ zend_declare_property_null(yaf_registry_ce, ZEND_STRL(YAF_REGISTRY_PROPERTY_NAME_INSTANCE), ZEND_ACC_STATIC);
+ zend_declare_property_null(yaf_registry_ce, ZEND_STRL(YAF_REGISTRY_PROPERTY_NAME_ENTRYS), ZEND_ACC_PROTECTED);
+
+ return SUCCESS;
+diff --git a/yaf_session.c b/yaf_session.c
+index 65d6184..e08117f 100644
+--- a/yaf_session.c
++++ b/yaf_session.c
+@@ -371,7 +371,7 @@ YAF_STARTUP_FUNCTION(session) {
+ zend_class_implements(yaf_session_ce, 2, zend_ce_iterator, zend_ce_arrayaccess);
+ #endif
+
+- zend_declare_property_null(yaf_session_ce, ZEND_STRL(YAF_SESSION_PROPERTY_NAME_INSTANCE), ZEND_ACC_PROTECTED|ZEND_ACC_STATIC);
++ zend_declare_property_null(yaf_session_ce, ZEND_STRL(YAF_SESSION_PROPERTY_NAME_INSTANCE), ZEND_ACC_STATIC);
+ zend_declare_property_null(yaf_session_ce, ZEND_STRL(YAF_SESSION_PROPERTY_NAME_SESSION), ZEND_ACC_PROTECTED);
+ zend_declare_property_bool(yaf_session_ce, ZEND_STRL(YAF_SESSION_PROPERTY_NAME_STATUS), 0, ZEND_ACC_PROTECTED);
+
diff --git a/php-pecl-yaf.spec b/php-pecl-yaf.spec
index 2701814..98afcac 100644
--- a/php-pecl-yaf.spec
+++ b/php-pecl-yaf.spec
@@ -28,10 +28,10 @@ Summary: Yet Another Framework
Name: %{?sub_prefix}php-pecl-yaf
Version: 3.0.7
%if 0%{?gh_date:1}
-Release: 0.10.%{gh_date}git%{gh_short}%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}
+Release: 0.11.%{gh_date}git%{gh_short}%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}
Source0: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{pecl_name}-%{version}-%{gh_short}.tar.gz
%else
-Release: 2%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}
+Release: 3%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}
Source: http://pecl.php.net/get/%{pecl_name}-%{version}%{?prever}.tgz
%endif
License: PHP
@@ -39,6 +39,7 @@ URL: http://pecl.php.net/package/yaf
Source1: %{pecl_name}.ini
Patch0: https://github.com/laruence/yaf/commit/931dc56c7a53c388c21d679ae10dfe0b245aed32.patch
+Patch1: https://patch-diff.githubusercontent.com/raw/laruence/yaf/pull/410.patch
BuildRequires: %{?dtsprefix}gcc
BuildRequires: %{?scl_prefix}php-devel >= 7
@@ -78,6 +79,10 @@ Obsoletes: php71w-pecl-%{pecl_name} <= %{version}
Obsoletes: php72u-pecl-%{pecl_name} <= %{version}
Obsoletes: php72w-pecl-%{pecl_name} <= %{version}
%endif
+%if "%{php_version}" > "7.3"
+Obsoletes: php73u-pecl-%{pecl_name} <= %{version}
+Obsoletes: php73w-pecl-%{pecl_name} <= %{version}
+%endif
%endif
%if 0%{?fedora} < 20 && 0%{?rhel} < 7
@@ -110,6 +115,7 @@ sed -e 's/role="test"/role="src"/' \
cd NTS
%patch0 -p1 -b .up
+%patch1 -p1 -b .pr410
# Sanity check, really often broken
extver=$(sed -n '/#define PHP_YAF_VERSION/{s/.*\t"//;s/".*$//;p}' php_yaf.h )
@@ -231,6 +237,11 @@ fi
%changelog
+* Wed Jul 18 2018 Remi Collet <remi@remirepo.net> - 3.0.7-3
+- rebuild for 7.3.0alpha4 new ABI
+- add patch for 7.3.0 from
+ https://github.com/laruence/yaf/pull/410
+
* Thu Jun 28 2018 Remi Collet <remi@remirepo.net> - 3.0.7-2
- add upstream patch for PHP 7.3