diff options
author | Remi Collet <remi@remirepo.net> | 2024-10-15 14:49:56 +0200 |
---|---|---|
committer | Remi Collet <remi@php.net> | 2024-10-15 14:49:56 +0200 |
commit | 0ecb8a8fff2895b1de4e5254e986253536bfce43 (patch) | |
tree | 469712510ce918cef1ea0d30baf144ada668f6fa /php-pecl-imap.spec | |
parent | 6531147a0c69337b9e099577e886a32f2b2f3e96 (diff) |
Diffstat (limited to 'php-pecl-imap.spec')
-rw-r--r-- | php-pecl-imap.spec | 88 |
1 files changed, 17 insertions, 71 deletions
diff --git a/php-pecl-imap.spec b/php-pecl-imap.spec index ca58e0b..7e1493e 100644 --- a/php-pecl-imap.spec +++ b/php-pecl-imap.spec @@ -11,21 +11,18 @@ %bcond_without tests -%global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} %global pecl_name imap %global ini_name 30-%{pecl_name}.ini %global sources %{pecl_name}-%{version} -%global _configure ../%{sources}/configure Summary: Extension to operate with the IMAP protocol Name: %{?scl_prefix}php-pecl-%{pecl_name} -Version: 1.0.2 -Release: 4%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Version: 1.0.3 +Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} License: PHP-3.01 URL: https://pecl.php.net/package/%{pecl_name} Source0: https://pecl.php.net/get/%{sources}.tgz -Patch0: upstream.patch BuildRequires: make BuildRequires: %{?dtsprefix}gcc @@ -64,8 +61,6 @@ sed -e 's/role="test"/role="src"/' \ -i package.xml cd %{sources} -%patch -P0 -p1 - # Sanity check, really often broken extver=$(sed -n '/#define PHP_IMAP_VERSION/{s/.* "//;s/".*$//;p}' php_imap.h) if test "x${extver}" != "x%{version}%{?prever}"; then @@ -80,56 +75,36 @@ cat >%{ini_name} << 'EOF' extension=%{pecl_name} EOF -mkdir NTS -%if %{with_zts} -mkdir ZTS -%endif - %build -%{?dtsenable} +cd %{sources} +%{__phpize} +sed -e 's/INSTALL_ROOT/DESTDIR/' -i build/Makefile.global -peclconf() { %configure \ --with-imap \ --with-kerberos \ --with-imap-ssl \ --with-libdir=%{_lib} \ - --with-php-config=$1 -} -cd %{sources} -%{__phpize} -sed -e 's/INSTALL_ROOT/DESTDIR/' -i build/Makefile.global - -cd ../NTS -peclconf %{__phpconfig} - -%make_build - -%if %{with_zts} -cd ../ZTS -peclconf %{__ztsphpconfig} + --with-php-config=%{__phpconfig} %make_build -%endif %install %{?dtsenable} -%make_install -C NTS +: Install configuration install -D -m 644 %{ini_name} %{buildroot}%{php_inidir}/%{ini_name} -# Install XML package description +: Install XML package description install -D -m 644 package.xml %{buildroot}%{pecl_xmldir}/%{name}.xml -%if %{with_zts} -%make_install -C ZTS -install -D -m 644 %{ini_name} %{buildroot}%{php_ztsinidir}/%{ini_name} -%endif - -# Documentation +: Install the extension cd %{sources} +%make_install + +: Install the Documentation for i in $(grep 'role="doc"' ../package.xml | sed -e 's/^.*name="//;s/".*$//') do install -Dpm 644 $i %{buildroot}%{pecl_docdir}/%{pecl_name}/$i done @@ -137,7 +112,7 @@ done %check cd %{sources} -: minimal load test of NTS extension +: minimal load test of the extension %{__php} --no-php-ini \ --define extension=%{buildroot}%{php_extdir}/%{pecl_name}.so \ --modules | grep '^%{pecl_name}$' @@ -145,39 +120,12 @@ cd %{sources} OPT="%{?_smp_mflags} -q --show-diff" %if %{with tests} -: upstream test suite for NTS extension +: upstream test suite for the extension TEST_PHP_EXECUTABLE=%{__php} \ TEST_PHP_ARGS="-n -d extension=%{buildroot}%{php_extdir}/%{pecl_name}.so" \ %{__php} -n run-tests.php $OPT %endif -%if %{with_zts} -: minimal load test of ZTS extension -%{__ztsphp} --no-php-ini \ - --define extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so \ - --modules | grep '^%{pecl_name}$' -%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 %license %{sources}/LICENSE @@ -187,13 +135,11 @@ fi %config(noreplace) %{php_inidir}/%{ini_name} %{php_extdir}/%{pecl_name}.so -%if %{with_zts} -%config(noreplace) %{php_ztsinidir}/%{ini_name} -%{php_ztsextdir}/%{pecl_name}.so -%endif - %changelog +* Tue Oct 15 2024 Remi Collet <remi@remirepo.net> - 1.0.3-1 +- update to 1.0.3 + * Tue Sep 24 2024 Remi Collet <remi@remirepo.net> - 1.0.2-4 - rebuild for 8.4.0RC1 |