%define modname igbinary
Summary: Replacement for the standard PHP serializer
Name: %{php_name}-pecl-%{modname}
-Version: 2.0.0
+Version: 2.0.8
Release: 1
License: BSD
-Group: Libraries
-Source0: http://pecl.php.net/get/%{modname}-%{version}.tgz
-# Source0-md5: 89e1250807864d13df7b07710a187edf
+Group: Development/Languages/PHP
+Source0: https://pecl.php.net/get/%{modname}-%{version}.tgz
+# Source0-md5: d3cbbfe6224923fecdad266569b57535
Source2: %{modname}.ini
-URL: http://pecl.php.net/package/igbinary
+URL: https://pecl.php.net/package/igbinary
%{?with_tests:BuildRequires: %{php_name}-cli}
BuildRequires: %{php_name}-devel >= 4:5.2.0
%{?with_tests:BuildRequires: %{php_name}-pcre}
%description
Igbinary is a drop in replacement for the standard PHP serializer.
-Instead of time and space consuming textual representation, igbinary
-stores PHP data structures in a compact binary form. Savings are
-significant when using memcached or similar memory based storages for
-serialized data.
+Instead of the time and space consuming textual representation used by
+PHP's serialize, igbinary stores php data structures in a compact
+binary form. Memory savings are significant when using memcached,
+APCu, or similar memory based storages for serialized data. The
+typical reduction in storage requirements are around 50%. The exact
+percentage depends on your data.
%package devel
Summary: Igbinary developer files (header)
%setup -qc
mv %{modname}-*/* .
+cat <<'EOF' > run-tests.sh
+#!/bin/sh
+export NO_INTERACTION=1 REPORT_EXIT_STATUS=1 MALLOC_CHECK_=2
+exec %{__make} test \
+ PHP_EXECUTABLE=%{__php} \
+ PHP_TEST_SHARED_SYSTEM_EXTENSIONS="pcre spl simplexml session" \
+ RUN_TESTS_SETTINGS="-q $*"
+EOF
+chmod +x run-tests.sh
+
+xfail() {
+ local t=$1
+ test -f $t
+ cat >> $t <<-EOF
+
+ --XFAIL--
+ Skip
+ EOF
+}
+
+while read line; do
+ t=${line##*\[}; t=${t%\]}
+ xfail $t
+done << 'EOF'
+Test serializing multiple reference groups to the same empty array [tests/igbinary_067.phpt]
+EOF
+
%build
phpize
%configure
%{__make}
-%if %{with tests}
-# APC required for test 045
-
# simple module load test
# without APC to ensure that can run without
%{__php} -n -q \
-m > modules.log
grep %{modname} modules.log
-cat <<'EOF' > run-tests.sh
-#!/bin/sh
-%{__make} test \
- PHP_EXECUTABLE=%{__php} \
- PHP_TEST_SHARED_SYSTEM_EXTENSIONS="pcre spl simplexml session" \
- RUN_TESTS_SETTINGS="-q $*"
-EOF
-
-chmod +x run-tests.sh
-./run-tests.sh -w failed.log --show-out
-test -f failed.log -a ! -s failed.log
+%if %{with tests}
+# APC required for test 045
+./run-tests.sh --show-diff
%endif
%install