From 2394aab0148961b680838786aa4a1ad96c818e14 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Fri, 9 Aug 2024 11:16:52 +0200 Subject: clean --- php-pecl-yaml.spec | 67 ++++++++++++++++-------------------------------------- 1 file changed, 20 insertions(+), 47 deletions(-) (limited to 'php-pecl-yaml.spec') diff --git a/php-pecl-yaml.spec b/php-pecl-yaml.spec index 23e97ca..d724e77 100644 --- a/php-pecl-yaml.spec +++ b/php-pecl-yaml.spec @@ -1,6 +1,6 @@ # remirepo spec file for php-pecl-yaml # -# Copyright (c) 2012-2023 Remi Collet +# Copyright (c) 2012-2024 Remi Collet # Fedora spec file for php-pecl-yaml # @@ -9,15 +9,13 @@ # # Please, preserve the changelog entries # -%if 0%{?scl:1} -%scl_package php-pecl-yaml -%endif +%{?scl:%scl_package php-pecl-yaml} -%bcond_without tests +%bcond_without tests -%global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} -%global pecl_name yaml -%global ini_name 40-%{pecl_name}.ini +%global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} +%global pecl_name yaml +%global ini_name 40-%{pecl_name}.ini %global upstream_version 2.2.3 #global upstream_prever b2 @@ -27,12 +25,16 @@ Summary: PHP Bindings for yaml Name: %{?scl_prefix}php-pecl-yaml Version: %{upstream_version}%{?upstream_prever:~%{upstream_prever}} -Release: 3%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Release: 4%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} License: MIT URL: https://pecl.php.net/package/yaml Source0: https://pecl.php.net/get/%{pecl_name}-%{upstream_version}%{?upstream_prever}.tgz +Patch0: %{pecl_name}-build.patch + +ExcludeArch: %{ix86} + BuildRequires: make BuildRequires: %{?dtsprefix}gcc BuildRequires: %{?scl_prefix}php-devel >= 7.1 @@ -47,27 +49,12 @@ Provides: %{?scl_prefix}php-%{pecl_name}%{?_isa} = %{version} Provides: %{?scl_prefix}php-pecl(%{pecl_name}) = %{version} Provides: %{?scl_prefix}php-pecl(%{pecl_name})%{?_isa} = %{version} -%if "%{?packager}" == "Remi Collet" && 0%{!?scl:1} && 0%{?rhel} == 7 -# Other third party repo stuff -Obsoletes: php56u-pecl-%{pecl_name} <= %{version} -Obsoletes: php71u-pecl-%{pecl_name} <= %{version} -%if "%{php_version}" > "7.2" -Obsoletes: php72u-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "7.3" -Obsoletes: php73-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "7.4" -Obsoletes: php74-pecl-%{pecl_name} <= %{version} -%endif -%endif - %description Support for YAML 1.1 (YAML Ain't Markup Language) serialization using the LibYAML library. -Documentation: http://php.net/yaml +Documentation: https://php.net/yaml Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')%{?scl: as Software Collection (%{scl} by %{?scl_vendor}%{!?scl_vendor:rh})}. @@ -77,10 +64,12 @@ Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSIO # Remove test file to avoid regsitration sed -e 's/role="test"/role="src"/' \ - %{?_licensedir:-e '/LICENSE/s/role="doc"/role="src"/' } \ + -e '/LICENSE/s/role="doc"/role="src"/' \ -i package.xml cd %{sources} +%patch -P0 -p1 + # Check upstream version (often broken) extver=$(sed -n '/#define PHP_YAML_VERSION/{s/.* "//;s/".*$//;p}' php_yaml.h) if test "x${extver}" != "x%{upstream_version}%{?upstream_prever}"; then @@ -193,28 +182,8 @@ REPORT_EXIT_STATUS=1 \ %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} +%license %{sources}/LICENSE %doc %{pecl_docdir}/%{pecl_name} %{pecl_xmldir}/%{name}.xml @@ -228,6 +197,10 @@ fi %changelog +* Mon Feb 19 2024 Remi Collet - 2.2.3-4 +- fix incompatible-pointer-types using patch from + https://github.com/php/pecl-file_formats-yaml/pull/74 + * Wed Aug 30 2023 Remi Collet - 2.2.3-3 - rebuild for PHP 8.3.0RC1 -- cgit