diff options
-rw-r--r-- | php-pecl-ds.spec | 36 |
1 files changed, 7 insertions, 29 deletions
diff --git a/php-pecl-ds.spec b/php-pecl-ds.spec index b9156b5..93c9c39 100644 --- a/php-pecl-ds.spec +++ b/php-pecl-ds.spec @@ -1,6 +1,6 @@ # remirepo spec file for php-pecl-ds # -# Copyright (c) 2016-2023 Remi Collet +# Copyright (c) 2016-2024 Remi Collet # License: CC-BY-SA-4.0 # http://creativecommons.org/licenses/by-sa/4.0/ # @@ -76,7 +76,7 @@ Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSIO mv %{gh_project}-%{gh_commit} tests # Don't install/register tests, install examples as doc -%{?_licensedir:sed -e '/LICENSE/s/role="doc"/role="src"/' -i package.xml} +sed -e '/LICENSE/s/role="doc"/role="src"/' -i package.xml cd %{sources} # Sanity check, really often broken @@ -107,11 +107,12 @@ peclbuild() { --enable-ds \ --with-php-config=$1 -make %{?_smp_mflags} +%make_build } cd %{sources} %{__phpize} +sed -e 's/INSTALL_ROOT/DESTDIR/' -i build/Makefile.global cd ../NTS peclbuild %{__phpconfig} @@ -125,8 +126,7 @@ peclbuild %{__ztsphpconfig} %install %{?dtsenable} -make -C NTS \ - install INSTALL_ROOT=%{buildroot} +%make_install -C NTS # install config file install -D -m 644 %{ini_name} %{buildroot}%{php_inidir}/%{ini_name} @@ -135,8 +135,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 -C ZTS \ - install INSTALL_ROOT=%{buildroot} +%make_install -C ZTS install -D -m 644 %{ini_name} %{buildroot}%{php_ztsinidir}/%{ini_name} %endif @@ -147,26 +146,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 [ -f %{php_extdir}/json.so ] && modules="-d extension=json.so" @@ -201,8 +180,7 @@ fi %files -%{?_licensedir:%license %{sources}/LICENSE} -%{!?_licensedir:%doc %{pecl_docdir}/%{pecl_name}} +%license %{sources}/LICENSE %{pecl_xmldir}/%{name}.xml %config(noreplace) %{php_inidir}/%{ini_name} |