diff options
author | Remi Collet <remi@remirepo.net> | 2020-08-16 08:34:45 +0200 |
---|---|---|
committer | Remi Collet <remi@remirepo.net> | 2020-08-16 08:34:45 +0200 |
commit | 5f7225f95b650f16e6682ab7057c1f486c397afa (patch) | |
tree | 394a618e4be400c666f2cbaeec925c0bd41dfe4e | |
parent | 02d6f45f5111af3e73c7d906a6d9ca2fa641b4d3 (diff) |
update to 2.2.0b1
drop patches merged upstream
-rw-r--r-- | .gitignore | 2 | ||||
-rw-r--r-- | 45.patch | 56 | ||||
-rw-r--r-- | 53.patch | 59 | ||||
-rw-r--r-- | PHPINFO | 2 | ||||
-rw-r--r-- | REFLECTION | 2 | ||||
-rw-r--r-- | php-pecl-yaml.spec | 30 |
6 files changed, 17 insertions, 134 deletions
@@ -1,5 +1,7 @@ +clog package-*.xml *.tgz +*.tar.bz2 *.tar.gz *.tar.xz *.tar.xz.asc diff --git a/45.patch b/45.patch deleted file mode 100644 index f2b9593..0000000 --- a/45.patch +++ /dev/null @@ -1,56 +0,0 @@ -From eb11e4e425d3d6e703c824fb891b1b0701d683ef Mon Sep 17 00:00:00 2001 -From: Remi Collet <remi@remirepo.net> -Date: Thu, 23 Apr 2020 08:16:30 +0200 -Subject: [PATCH 1/2] fix [-Wformat=] issue on 32-bit - ---- - emit.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/emit.c b/emit.c -index 0fd2ebc..234a64e 100644 ---- a/emit.c -+++ b/emit.c -@@ -506,9 +506,9 @@ static int y_write_array( - recursive_idx = y_search_recursive(state, (zend_ulong) ht); - if (-1 != recursive_idx) { - /* create anchor to refer to this structure */ -- anchor_size = snprintf(anchor, 0, "refid%ld", recursive_idx + 1); -+ anchor_size = snprintf(anchor, 0, "refid" ZEND_LONG_FMT, recursive_idx + 1); - anchor = (char*) emalloc(anchor_size + 1); -- snprintf(anchor, anchor_size + 1, "refid%ld", recursive_idx + 1); -+ snprintf(anchor, anchor_size + 1, "refid" ZEND_LONG_FMT, recursive_idx + 1); - - #if PHP_VERSION_ID >= 70300 - if (!(GC_FLAGS(ht) & GC_IMMUTABLE) && GC_IS_RECURSIVE(ht)) { - -From a5a7f14f37c1d530e8e9868945f4c08af26ba8a9 Mon Sep 17 00:00:00 2001 -From: Remi Collet <remi@remirepo.net> -Date: Thu, 23 Apr 2020 08:16:55 +0200 -Subject: [PATCH 2/2] relax test on 32-bit (overflow to float) - ---- - tests/bug_79494.phpt | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) - -diff --git a/tests/bug_79494.phpt b/tests/bug_79494.phpt -index d388bd8..f4f8b48 100644 ---- a/tests/bug_79494.phpt -+++ b/tests/bug_79494.phpt -@@ -22,13 +22,13 @@ $data = array ( - - print yaml_emit($data); - ?> ----EXPECT-- -+--EXPECTF-- - --- - audio: - audioEnabled: -- - 132317787432502136 -+ - 13231778%s - - 0 - eveampGain: -- - 132316833510704299 -+ - 13231683%s - - 0.250000 - ... diff --git a/53.patch b/53.patch deleted file mode 100644 index 25cb671..0000000 --- a/53.patch +++ /dev/null @@ -1,59 +0,0 @@ -From ebc51a7314881805f9b8fda2ac19285465f48d3e Mon Sep 17 00:00:00 2001 -From: Andy Postnikov <apostnikov@gmail.com> -Date: Sat, 11 Jul 2020 19:43:18 +0300 -Subject: [PATCH] Fix build on PHP 8 alpha 2 - -call_user_function_ex() no longer defined ---- - emit.c | 4 ++-- - parse.c | 8 ++++---- - 2 files changed, 6 insertions(+), 6 deletions(-) - -diff --git a/emit.c b/emit.c -index 234a64e..cc5134b 100644 ---- a/emit.c -+++ b/emit.c -@@ -722,8 +722,8 @@ y_write_object_callback ( - zend_string *str_key; - - /* call the user function */ -- if (FAILURE == call_user_function_ex(EG(function_table), NULL, -- callback, &zret, 1, argv, 0, NULL) || -+ if (FAILURE == call_user_function(EG(function_table), NULL, -+ callback, &zret, 1, argv) || - Z_TYPE_P(&zret) == IS_UNDEF) { - php_error_docref(NULL, E_WARNING, - "Failed to apply callback for class '%s'" -diff --git a/parse.c b/parse.c -index 71eb4f2..2405c58 100644 ---- a/parse.c -+++ b/parse.c -@@ -643,7 +643,7 @@ apply_filter(zval *zp, yaml_event_t event, HashTable *callbacks) - ZVAL_LONG(&callback_args[2], 0); - - /* call the user function */ -- callback_result = call_user_function_ex(EG(function_table), NULL, callback, &retval, 3, callback_args, 0, NULL); -+ callback_result = call_user_function(EG(function_table), NULL, callback, &retval, 3, callback_args); - - /* cleanup our temp variables */ - zval_ptr_dtor(&callback_args[1]); -@@ -846,7 +846,7 @@ void eval_scalar_with_callbacks(yaml_event_t event, - ZVAL_STRINGL(&argv[1], tag, strlen(tag)); - ZVAL_LONG(&argv[2], event.data.scalar.style); - -- if (FAILURE == call_user_function_ex(EG(function_table), NULL, callback, retval, 3, argv, 0, NULL) || Z_TYPE_P(retval) == IS_UNDEF) { -+ if (FAILURE == call_user_function(EG(function_table), NULL, callback, retval, 3, argv) || Z_TYPE_P(retval) == IS_UNDEF) { - php_error_docref(NULL, E_WARNING, - "Failed to evaluate value for tag '%s'" - " with user defined function", tag); -@@ -898,8 +898,8 @@ eval_timestamp(zval **zpp, const char *ts, size_t ts_len) - ZVAL_STRINGL(&arg, ts, ts_len); - argv[0] = arg; - -- if (FAILURE == call_user_function_ex(EG(function_table), NULL, func, -- &retval, 1, argv, 0, NULL) || Z_TYPE_P(&retval) == IS_UNDEF) { -+ if (FAILURE == call_user_function(EG(function_table), NULL, func, -+ &retval, 1, argv) || Z_TYPE_P(&retval) == IS_UNDEF) { - php_error_docref(NULL, E_WARNING, - "Failed to evaluate string '%s' as timestamp", ts); - if (func != NULL) { @@ -2,7 +2,7 @@ yaml LibYAML Support => enabled -Module Version => 2.1.0 +Module Version => 2.2.0b1 LibYAML Version => 0.2.2 Directive => Local Value => Master Value @@ -1,4 +1,4 @@ -Extension [ <persistent> extension #101 yaml version 2.1.0 ] { +Extension [ <persistent> extension #104 yaml version 2.2.0b1 ] { - Dependencies { Dependency [ date (Optional) ] diff --git a/php-pecl-yaml.spec b/php-pecl-yaml.spec index ed6c0b0..b9eab7a 100644 --- a/php-pecl-yaml.spec +++ b/php-pecl-yaml.spec @@ -17,19 +17,18 @@ %global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} %global pecl_name yaml %global ini_name 40-%{pecl_name}.ini -#global prever RC8 + +%global upstream_version 2.2.0 +%global upstream_prever b1 Summary: PHP Bindings for yaml Name: %{?sub_prefix}php-pecl-yaml -Version: 2.1.0 -Release: 3%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Version: %{upstream_version}%{?upstream_prever:~%{upstream_prever}} +Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} License: MIT URL: https://pecl.php.net/package/yaml -Source: https://pecl.php.net/get/%{pecl_name}-%{version}%{?prever}.tgz - -Patch0: https://patch-diff.githubusercontent.com/raw/php/pecl-file_formats-yaml/pull/45.patch -Patch1: https://patch-diff.githubusercontent.com/raw/php/pecl-file_formats-yaml/pull/53.patch +Source0: https://pecl.php.net/get/%{pecl_name}-%{upstream_version}%{?upstream_prever}.tgz BuildRequires: %{?dtsprefix}gcc BuildRequires: %{?scl_prefix}php-devel >= 7.1 @@ -92,7 +91,7 @@ Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSIO %prep %setup -c -q -mv %{pecl_name}-%{version}%{?prever} NTS +mv %{pecl_name}-%{upstream_version}%{?upstream_prever} NTS # Remove test file to avoid regsitration sed -e 's/role="test"/role="src"/' \ @@ -100,13 +99,10 @@ sed -e 's/role="test"/role="src"/' \ -i package.xml cd NTS -%patch0 -p1 -b .pr45 -%patch1 -p1 -b .pr52 - # Check upstream version (often broken) extver=$(sed -n '/#define PHP_YAML_VERSION/{s/.* "//;s/".*$//;p}' php_yaml.h) -if test "x${extver}" != "x%{version}%{?prever}"; then - : Error: Upstream version is ${extver}, expecting %{version}%{?prever}. +if test "x${extver}" != "x%{upstream_version}%{?upstream_prever}"; then + : Error: Upstream extension version is ${extver}, expecting %{upstream_version}%{?upstream_prever}. exit 1 fi cd .. @@ -185,10 +181,6 @@ done %check -%if "%{php_version}" > "8.0" -# warnings promoted to exception -rm ?TS/tests/yaml_parse_file_002.phpt -%endif cd NTS : Minimal load test for NTS extension %{__php} --no-php-ini \ @@ -254,6 +246,10 @@ fi %changelog +* Sun Aug 16 2020 Remi Collet <remi@remirepo.net> - 2.2.0~b1-1 +- update to 2.2.0b1 +- drop patches merged upstream + * Wed Aug 5 2020 Remi Collet <remi@remirepo.net> - 2.1.0-3 - rebuild for 8.0.0beta1 |