From c60391afab65e634eab6193fb4b6b2423034509f Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Wed, 18 Jul 2018 13:09:10 +0200 Subject: rebuild for 7.3.0alpha4 new ABI, using patch from https://github.com/php/pecl-database-mysql_xdevapi/pull/5 --- 5.patch | 83 +++++++++++++++++++++++++++++++++++++++++++++ php-pecl-mysql-xdevapi.spec | 12 ++++++- 2 files changed, 94 insertions(+), 1 deletion(-) create mode 100644 5.patch diff --git a/5.patch b/5.patch new file mode 100644 index 0000000..a545044 --- /dev/null +++ b/5.patch @@ -0,0 +1,83 @@ +From 56893f68273cd9d1353645ffc3f39861e39bb7c9 Mon Sep 17 00:00:00 2001 +From: Remi Collet +Date: Wed, 18 Jul 2018 13:03:28 +0200 +Subject: [PATCH] fix for 7.3.0alpha4 + +--- + mysqlx_base_result_iterator.cc | 2 ++ + mysqlx_doc_result_iterator.cc | 2 ++ + mysqlx_result_iterator.cc | 2 ++ + mysqlx_row_result_iterator.cc | 2 ++ + mysqlx_sql_statement_result_iterator.cc | 2 ++ + 5 files changed, 10 insertions(+) + +diff --git a/mysqlx_base_result_iterator.cc b/mysqlx_base_result_iterator.cc +index 2c9eae4..0a7c315 100644 +--- a/mysqlx_base_result_iterator.cc ++++ b/mysqlx_base_result_iterator.cc +@@ -193,7 +193,9 @@ void + mysqlx_register_base_result_iterator(zend_class_entry * ce) + { + ce->get_iterator = mysqlx_base_result_create_iterator; ++#if PHP_VERSION_ID < 70300 + ce->iterator_funcs.funcs = &mysqlx_base_result_iterator_funcs; ++#endif + + zend_class_implements(ce, 1, zend_ce_traversable); + } +diff --git a/mysqlx_doc_result_iterator.cc b/mysqlx_doc_result_iterator.cc +index 9c57a21..2536ad1 100644 +--- a/mysqlx_doc_result_iterator.cc ++++ b/mysqlx_doc_result_iterator.cc +@@ -198,7 +198,9 @@ void + mysqlx_register_doc_result_iterator(zend_class_entry * ce) + { + ce->get_iterator = mysqlx_doc_result_create_iterator; ++#if PHP_VERSION_ID < 70300 + ce->iterator_funcs.funcs = &mysqlx_doc_result_iterator_funcs; ++#endif + + zend_class_implements(ce, 1, zend_ce_traversable); + } +diff --git a/mysqlx_result_iterator.cc b/mysqlx_result_iterator.cc +index ff52615..46f251c 100644 +--- a/mysqlx_result_iterator.cc ++++ b/mysqlx_result_iterator.cc +@@ -192,7 +192,9 @@ void + mysqlx_register_result_iterator(zend_class_entry * ce) + { + ce->get_iterator = mysqlx__result_create_iterator; ++#if PHP_VERSION_ID < 70300 + ce->iterator_funcs.funcs = &mysqlx__result_iterator_funcs; ++#endif + + zend_class_implements(ce, 1, zend_ce_traversable); + } +diff --git a/mysqlx_row_result_iterator.cc b/mysqlx_row_result_iterator.cc +index a26617d..77eebf9 100644 +--- a/mysqlx_row_result_iterator.cc ++++ b/mysqlx_row_result_iterator.cc +@@ -192,7 +192,9 @@ void + mysqlx_register_row_result_iterator(zend_class_entry * ce) + { + ce->get_iterator = mysqlx_row_result_create_iterator; ++#if PHP_VERSION_ID < 70300 + ce->iterator_funcs.funcs = &mysqlx_row_result_iterator_funcs; ++#endif + + zend_class_implements(ce, 1, zend_ce_traversable); + } +diff --git a/mysqlx_sql_statement_result_iterator.cc b/mysqlx_sql_statement_result_iterator.cc +index 55640b4..a970244 100644 +--- a/mysqlx_sql_statement_result_iterator.cc ++++ b/mysqlx_sql_statement_result_iterator.cc +@@ -191,7 +191,9 @@ void + mysqlx_register_sql_statement_result_iterator(zend_class_entry * ce) + { + ce->get_iterator = mysqlx_sql_result_create_iterator; ++#if PHP_VERSION_ID < 70300 + ce->iterator_funcs.funcs = &mysqlx_sql_result_iterator_funcs; ++#endif + + zend_class_implements(ce, 1, zend_ce_traversable); + } diff --git a/php-pecl-mysql-xdevapi.spec b/php-pecl-mysql-xdevapi.spec index cac0920..c56a2b0 100644 --- a/php-pecl-mysql-xdevapi.spec +++ b/php-pecl-mysql-xdevapi.spec @@ -25,13 +25,14 @@ Summary: MySQL database access functions Name: %{?sub_prefix}php-pecl-mysql-xdevapi Version: 8.0.11 -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;')}} License: PHP URL: http://pecl.php.net/package/%{pecl_name} Source0: http://pecl.php.net/get/%{pecl_name}-%{version}%{?prever}.tgz Patch0: https://github.com/php/pecl-database-mysql_xdevapi/commit/f7fe2b6f7a184c92ff50290f3c2adfd4dcead010.patch +Patch1: https://patch-diff.githubusercontent.com/raw/php/pecl-database-mysql_xdevapi/pull/5.patch BuildRequires: %{?dtsprefix}gcc BuildRequires: %{?dtsprefix}gcc-c++ @@ -75,6 +76,10 @@ Obsoletes: php71w-pecl-%{pecl_name} <= %{version} Obsoletes: php72u-pecl-%{pecl_name} <= %{version} Obsoletes: php72w-pecl-%{pecl_name} <= %{version} %endif +%if "%{php_version}" > "7.2" +Obsoletes: php73u-pecl-%{pecl_name} <= %{version} +Obsoletes: php73w-pecl-%{pecl_name} <= %{version} +%endif %endif %if 0%{?fedora} < 20 && 0%{?rhel} < 7 @@ -124,6 +129,7 @@ sed -e 's/role="test"/role="src"/' \ cd NTS %patch0 -p1 -b .upstream +%patch1 -p1 -b .pr5 # Check version as upstream often forget to update this extver=$(sed -n '/#define PHP_MYSQL_XDEVAPI_VERSION/{s/.* "//;s/".*$//;p}' php_mysql_xdevapi.h) @@ -312,6 +318,10 @@ fi %changelog +* Wed Jul 18 2018 Remi Collet - 8.0.11-3 +- rebuild for 7.3.0alpha4 new ABI, using patch from + https://github.com/php/pecl-database-mysql_xdevapi/pull/5 + * Fri Jun 29 2018 Remi Collet - 8.0.11-2 - add upstream patch for 7.3 -- cgit