diff options
author | Remi Collet <remi@remirepo.net> | 2024-07-04 08:32:54 +0200 |
---|---|---|
committer | Remi Collet <remi@php.net> | 2024-07-04 08:32:54 +0200 |
commit | 4db2d069f3174b5d3a6da3fe0ec0a8d29fb17c2d (patch) | |
tree | 6a2c4d65f6afc3a9ec4f3c56ccd279b207e1277a /php-pecl-zip.spec | |
parent | fa18cd439d3cf9c17d9c6f8b34470946ecf36fb8 (diff) |
add upstream patches for PHP 8.4
Diffstat (limited to 'php-pecl-zip.spec')
-rw-r--r-- | php-pecl-zip.spec | 78 |
1 files changed, 10 insertions, 68 deletions
diff --git a/php-pecl-zip.spec b/php-pecl-zip.spec index aa4658f..79a7d9f 100644 --- a/php-pecl-zip.spec +++ b/php-pecl-zip.spec @@ -3,7 +3,7 @@ # # fedora spec file for php-pecl-zip # -# Copyright (c) 2013-2023 Remi Collet +# Copyright (c) 2013-2024 Remi Collet # License: CC-BY-SA-4.0 # http://creativecommons.org/licenses/by-sa/4.0/ # @@ -12,11 +12,6 @@ %{?scl:%scl_package php-pecl-zip} -# For PHP < 5.6 and EPEL-9 -%{!?__phpize: %global __phpize %{_bindir}/phpize} -%{!?__ztsphpize: %global __ztsphpize %{_bindir}/zts-phpize} -%{!?__phpconfig: %global __phpconfig %{_bindir}/php-config} -%{!?__ztsphpconfig:%global __ztsphpconfig %{_bindir}/zts-php-config} %if ( 0%{?scl:1} && 0%{?rhel} == 8 ) || 0%{?rhel} >= 9 %bcond_without move_to_opt @@ -47,12 +42,14 @@ Summary: A ZIP archive management extension Name: %{?scl_prefix}php-pecl-zip Version: %{upstream_version}%{?upstream_prever:~%{upstream_lower}} -Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Release: 2%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} License: PHP-3.01 Group: Development/Languages URL: https://pecl.php.net/package/zip Source0: https://pecl.php.net/get/%{sources}.tgz +Patch0: upstream.patch +Patch1: zip-php84.patch BuildRequires: make BuildRequires: %{?dtsprefix}gcc @@ -66,14 +63,9 @@ Requires: %{?vendeur:%{vendeur}-}libzip%{?_isa} >= %{libzip_version} %global __requires_exclude ^libzip\\.so.*$ %else # Ensure latest version is used -%if 0%{?rhel} == 7 -BuildRequires: libzip5-devel >= %{libzip_version} -Requires: libzip5%{?_isa} >= %{libzip_version} -%else BuildRequires: libzip-devel >= %{libzip_version} Requires: libzip%{?_isa} >= %{libzip_version} %endif -%endif Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api} Requires: %{?scl_prefix}php(api) = %{php_core_api} @@ -83,42 +75,6 @@ Provides: %{?scl_prefix}php-pecl(%{pecl_name})%{?_isa} = %{version} Provides: %{?scl_prefix}php-%{pecl_name} = 1:%{version}-%{release} Provides: %{?scl_prefix}php-%{pecl_name}%{?_isa} = 1:%{version}-%{release} -%if "%{?packager}" == "Remi Collet" && 0%{!?scl:1} && 0%{?rhel} == 7 -# Other third party repo stuff -Obsoletes: php53-pecl-%{pecl_name} <= %{version} -Obsoletes: php53u-pecl-%{pecl_name} <= %{version} -Obsoletes: php54-pecl-%{pecl_name} <= %{version} -Obsoletes: php54w-pecl-%{pecl_name} <= %{version} -%if "%{php_version}" > "5.5" -Obsoletes: php55u-pecl-%{pecl_name} <= %{version} -Obsoletes: php55w-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "5.6" -Obsoletes: php56u-pecl-%{pecl_name} <= %{version} -Obsoletes: php56w-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "7.0" -Obsoletes: php70u-pecl-%{pecl_name} <= %{version} -Obsoletes: php70w-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "7.1" -Obsoletes: php71u-pecl-%{pecl_name} <= %{version} -Obsoletes: php71w-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "7.2" -Obsoletes: php72u-pecl-%{pecl_name} <= %{version} -Obsoletes: php72w-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "7.3" -Obsoletes: php73-pecl-%{pecl_name} <= %{version} -Obsoletes: php73w-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "7.4" -Obsoletes: php74-pecl-%{pecl_name} <= %{version} -Obsoletes: php74w-pecl-%{pecl_name} <= %{version} -%endif -%endif - %if "%{php_version}" > "7.0" Obsoletes: %{?scl_prefix}php-zip <= 7.0.0 %endif @@ -141,6 +97,9 @@ sed -e 's/role="test"/role="src"/' \ -i package.xml cd %{sources} +%patch -P0 -p1 +%patch -P1 -p1 + # Sanity check, really often broken extver=$(sed -n '/#define PHP_ZIP_VERSION/{s/.* "//;s/".*$//;p}' php7/php_zip.h) if test "x${extver}" != "x%{upstream_version}%{?upstream_prever}" -a "x${extver}" != "x%{upstream_version}-%{?upstream_prever}"; then @@ -247,26 +206,6 @@ TEST_PHP_EXECUTABLE=%{__ztsphp} \ %endif -%if 0%{?fedora} < 24 && 0%{?rhel} < 8 -# when pear installed alone, after us -%triggerin -- %{?scl_prefix}php-pear -if [ -x %{__pecl} ] ; then - %{pecl_install} %{pecl_xmldir}/%{name}.xml >/dev/null || : -fi - -# posttrans as pear can be installed after us -%posttrans -if [ -x %{__pecl} ] ; then - %{pecl_install} %{pecl_xmldir}/%{name}.xml >/dev/null || : -fi - -%postun -if [ $1 -eq 0 -a -x %{__pecl} ] ; then - %{pecl_uninstall} %{pecl_name} >/dev/null || : -fi -%endif - - %files %{?_licensedir:%license %{sources}/LICENSE} %doc %{pecl_docdir}/%{pecl_name} @@ -282,6 +221,9 @@ fi %changelog +* Thu Jul 4 2024 Remi Collet <remi@remirepo.net> - 1.22.3-2 +- add upstream patches for PHP 8.4 + * Tue Nov 14 2023 Remi Collet <remi@remirepo.net> - 1.22.3-1 - update to 1.22.3 - build out of sources tree |