From d063ddfef598d55060d9835c5de1116aae6dde9a Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Tue, 1 Oct 2024 08:35:17 +0200 Subject: ignore test suite on F41 --- php-pecl-gnupg.spec | 69 +++++++++++++---------------------------------------- 1 file changed, 16 insertions(+), 53 deletions(-) diff --git a/php-pecl-gnupg.spec b/php-pecl-gnupg.spec index 8f05fb3..b78c13d 100644 --- a/php-pecl-gnupg.spec +++ b/php-pecl-gnupg.spec @@ -1,6 +1,6 @@ # spec file for php-pecl-gnupg # -# Copyright (c) 2012-2023 Remi Collet +# Copyright (c) 2012-2024 Remi Collet # License: CC-BY-SA-4.0 # http://creativecommons.org/licenses/by-sa/4.0/ # @@ -12,26 +12,16 @@ %global pecl_name gnupg %global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} -%if "%{php_version}" < "5.6" -%global ini_name %{pecl_name}.ini -%else %global ini_name 40-%{pecl_name}.ini -%endif %global upstream_version 1.5.1 #global upstream_prever RC2 %global sources %{pecl_name}-%{upstream_version}%{?upstream_prever} %global _configure ../%{sources}/configure -# 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} - Summary: Wrapper around the gpgme library Name: %{?scl_prefix}php-pecl-gnupg Version: %{upstream_version}%{?upstream_prever:~%{upstream_prever}} -Release: 3%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')} +Release: 4%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')} License: BSD-2-Clause URL: https://pecl.php.net/package/gnupg @@ -42,20 +32,12 @@ BuildRequires: %{?dtsprefix}gcc BuildRequires: %{?scl_prefix}php-devel BuildRequires: %{?scl_prefix}php-pear BuildRequires: gpgme-devel -%if 0%{?rhel} == 7 -BuildRequires: gnupg1 -%else BuildRequires: gnupg -%endif Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api} Requires: %{?scl_prefix}php(api) = %{php_core_api} # We force use of /usr/bin/gpg as gpg2 is unusable in non-interactive mode -%if 0%{?rhel} == 7 -Requires: gnupg1 -%else Requires: gnupg -%endif Provides: %{?scl_prefix}php-%{pecl_name} = %{version} Provides: %{?scl_prefix}php-%{pecl_name}%{?_isa} = %{version} @@ -76,7 +58,7 @@ Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSIO # Don't install/register tests 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 # Create configuration file @@ -106,26 +88,20 @@ mkdir ZTS export PHP_RPATH=no export CFLAGS="$RPM_OPT_FLAGS -D_FILE_OFFSET_BITS=64" -%if 0%{?rhel} == 7 -export GPG1=$(which gpg1 2>/dev/null || which gpg) -$GPG1 --version -%else gpg --version -%endif peclbuild() { %configure \ -%if 0%{?rhel} == 7 - --with-gpg=$GPG1 \ -%endif --with-libdir=%{_lib} \ --with-php-config=${1} -make %{?_smp_mflags} +%make_build } cd %{sources} %{__phpize} +[ -f Makefile.global ] && GLOBAL=Makefile.global || GLOBAL=build/Makefile.global +sed -e 's/INSTALL_ROOT/DESTDIR/' -i $GLOBAL cd ../NTS peclbuild %{__phpconfig} @@ -139,7 +115,7 @@ peclbuild %{__ztsphpconfig} %install %{?dtsenable} -make install -C NTS INSTALL_ROOT=%{buildroot} +%make_install -C NTS # Drop in the bit of configuration install -D -m 644 %{ini_name} %{buildroot}%{php_inidir}/%{ini_name} @@ -148,7 +124,7 @@ install -D -m 644 %{ini_name} %{buildroot}%{php_inidir}/%{ini_name} install -D -m 644 package.xml %{buildroot}%{pecl_xmldir}/%{name}.xml %if %{with_zts} -make install -C ZTS INSTALL_ROOT=%{buildroot} +%make_install -C ZTS install -D -m 644 %{ini_name} %{buildroot}%{php_ztsinidir}/%{ini_name} %endif @@ -158,26 +134,6 @@ do install -Dpm 644 %{sources}/$i %{buildroot}%{pecl_docdir}/%{pecl_name}/$i done -%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 - - %check cd %{sources} sed -e '/GnuPG v1/d' \ @@ -197,8 +153,12 @@ REPORT_EXIT_STATUS=1 \ %{__php} -n run-tests.php \ -n -q \ -d extension=%{buildroot}%{php_extdir}/%{pecl_name}.so \ +%if 0%{?fedora} >= 41 + --show-diff || : ignore failure +%else --show-diff %endif +%endif %if %{with_zts} : Check if build ZTS extension can be loaded @@ -209,7 +169,7 @@ REPORT_EXIT_STATUS=1 \ %files -%{?_licensedir:%license %{sources}/LICENSE} +%license %{sources}/LICENSE %doc %{pecl_docdir}/%{pecl_name} %{pecl_xmldir}/%{name}.xml @@ -223,6 +183,9 @@ REPORT_EXIT_STATUS=1 \ %changelog +* Tue Oct 1 2024 Remi Collet - 1.5.1-4 +- ignore test suite on F41 + * Wed Aug 30 2023 Remi Collet - 1.5.1-3 - rebuild for PHP 8.3.0RC1 -- cgit