This commit is contained in:
Remi Collet 2020-03-02 10:18:23 +01:00
parent 5c50da9bdd
commit 5b73291ef6
5 changed files with 19 additions and 2473 deletions

1
.gitignore vendored
View File

@ -5,3 +5,4 @@ clog
/msgpack-2.0.2.tgz
/msgpack-2.0.3-943d272.tar.gz
/msgpack-2.0.3.tgz
/msgpack-2.1.0.tgz

2420
124.patch

File diff suppressed because it is too large Load Diff

View File

@ -1,36 +0,0 @@
From 98d4af769b3c1ee42240c7dfb3799a2ce5edb3f3 Mon Sep 17 00:00:00 2001
From: Remi Collet <remi@remirepo.net>
Date: Tue, 26 Jun 2018 14:56:03 +0200
Subject: [PATCH] fix ce->name is a zend_string
---
msgpack_convert.c | 2 +-
msgpack_unpack.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/msgpack_convert.c b/msgpack_convert.c
index 117727e..85d1da6 100644
--- a/msgpack_convert.c
+++ b/msgpack_convert.c
@@ -314,7 +314,7 @@ int msgpack_convert_object(zval *return_value, zval *tpl, zval *value) /* {{{ */
if (zend_call_function(&fci, &fcc) == FAILURE) {
MSGPACK_WARNING(
"[msgpack] (%s) Invocation of %s's constructor failed",
- __FUNCTION__, ce->name);
+ __FUNCTION__, ZSTR_VAL(ce->name));
return FAILURE;
}
diff --git a/msgpack_unpack.c b/msgpack_unpack.c
index 263341b..6c3f30b 100644
--- a/msgpack_unpack.c
+++ b/msgpack_unpack.c
@@ -557,7 +557,7 @@ int msgpack_unserialize_map_item(msgpack_unserialize_data *unpack, zval **contai
if (ce->unserialize == NULL) {
MSGPACK_WARNING(
"[msgpack] (%s) Class %s has no unserializer",
- __FUNCTION__, ce->name);
+ __FUNCTION__, ZSTR_VAL(ce->name));
MSGPACK_UNSERIALIZE_FINISH_MAP_ITEM(unpack, key, val);

View File

@ -1,6 +1,6 @@
# Fedora spec file for php-pecl-msgpack
#
# Copyright (c) 2012-2018 Remi Collet
# Copyright (c) 2012-2020 Remi Collet
# License: CC-BY-SA
# http://creativecommons.org/licenses/by-sa/4.0/
#
@ -10,29 +10,31 @@
# we don't want -z defs linker flag
%undefine _strict_symbol_defs_build
%global upstream_version 2.1.0
#global upstream_prever beta1
#global upstream_lower beta1
%global pecl_name msgpack
%global with_zts 0%{?__ztsphp:1}
%global ini_name 40-%{pecl_name}.ini
# system library is outdated, and bundled library includes not yet released changes
# e.g. missing template_callback_str in 1.4.1
# BTW, only pack_template.h and unpack_template.h headers are used
%global with_msgpack 0
Summary: API for communicating with MessagePack serialization
Name: php-pecl-msgpack
Version: 2.0.3
Release: 3%{?dist}
Source: http://pecl.php.net/get/%{pecl_name}-%{version}.tgz
Version: %{upstream_version}%{?upstream_lower:~%{upstream_lower}}
Release: 1%{?dist}
Source: https://pecl.php.net/get/%{pecl_name}-%{upstream_version}%{?upstream_prever}.tgz
License: BSD
URL: http://pecl.php.net/package/msgpack
Patch2: https://patch-diff.githubusercontent.com/raw/msgpack/msgpack-php/pull/125.patch
URL: https://pecl.php.net/package/msgpack
BuildRequires: php-devel > 7
BuildRequires: php-pear
%if %{with_msgpack}
BuildRequires: msgpack-devel
%else
Provides: bundled(msgpack)
Provides: bundled(msgpack) = 3.2.0
%endif
# https://github.com/msgpack/msgpack-php/issues/25
ExcludeArch: ppc64
@ -73,13 +75,11 @@ These are the files needed to compile programs using MessagePack serializer.
%prep
%setup -qc
mv %{pecl_name}-%{version} NTS
mv %{pecl_name}-%{upstream_version}%{?upstream_prever} NTS
sed -e '/LICENSE/s/role="doc"/role="src"/' -i package.xml
cd NTS
%patch2 -p1 -b .pr125
%if %{with_msgpack}
# use system library
rm -rf msgpack
@ -90,8 +90,8 @@ rm -rf msgpack
# Sanity check, really often broken
extver=$(sed -n '/#define PHP_MSGPACK_VERSION/{s/.* "//;s/".*$//;p}' php_msgpack.h)
if test "x${extver}" != "x%{version}%{?gh_date:-dev}"; then
: Error: Upstream extension version is ${extver}, expecting %{version}%{?gh_date:-dev}.
if test "x${extver}" != "x%{upstream_version}%{?upstream_prever}%{?gh_date:-dev}"; then
: Error: Upstream extension version is ${extver}, expecting %{upstream_version}%{?upstream_prever}%{?gh_date:-dev}.
exit 1
fi
cd ..
@ -157,8 +157,6 @@ done
# Erratic results
rm */tests/034.phpt
# Known by upstream as failed test (travis result)
rm */tests/041.phpt
rm */tests/040*.phpt
cd NTS
: Minimal load test for NTS extension
@ -213,6 +211,9 @@ REPORT_EXIT_STATUS=0 \
%changelog
* Mon Mar 2 2020 Remi Collet <remi@remirepo.net> - 2.1.0-1
- update to 2.1.0
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.3-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild

View File

@ -1 +1 @@
SHA512 (msgpack-2.0.3.tgz) = 4eaf5d2cd50796349414d8272e210f1c8c2e82d72383f440e13d31742a75b0e2fa1f48bd916c057b4c65778bd90eace7dcc0cdb86931620963e666f3aa6905db
SHA512 (msgpack-2.1.0.tgz) = e024694076224796b2fb4dbd4473c5ac782951911437d0ee668231a1908f924a3a28dd616c0821929b425ee5ec06ef51f870f15b677171429049f4ae5f7befb7