summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemi Collet <fedora@famillecollet.com>2016-03-02 10:19:38 +0100
committerRemi Collet <fedora@famillecollet.com>2016-03-02 10:19:38 +0100
commit53e4c180c98a2345bf2bb60399dee53b90a56e1a (patch)
treee07a654ff1ddf7014c320b0fc6d7572a21c9eeea
parent5e5e2c77c8f81f127939c237a3d333e1b243609b (diff)
php-pecl-igbinary: cleanup
-rw-r--r--php-pecl-igbinary-dev.spec12
-rw-r--r--php-pecl-igbinary.spec14
2 files changed, 17 insertions, 9 deletions
diff --git a/php-pecl-igbinary-dev.spec b/php-pecl-igbinary-dev.spec
index b1138b5..9f0fb06 100644
--- a/php-pecl-igbinary-dev.spec
+++ b/php-pecl-igbinary-dev.spec
@@ -18,9 +18,6 @@
%endif
%{?scl: %scl_package php-pecl-igbinary}
-%{!?php_inidir: %global php_inidir %{_sysconfdir}/php.d}
-%{!?__pecl: %global __pecl %{_bindir}/pecl}
-%{!?__php: %global __php %{_bindir}/php}
%global extname igbinary
%global with_zts 0%{?__ztsphp:1}
@@ -62,6 +59,8 @@ Provides: %{?scl_prefix}php-%{extname} = %{version}
Provides: %{?scl_prefix}php-%{extname}%{?_isa} = %{version}
Provides: %{?scl_prefix}php-pecl(%{extname}) = %{version}
Provides: %{?scl_prefix}php-pecl(%{extname})%{?_isa} = %{version}
+Provides: %{?scl_prefix}php-pecl-%{pecl_name} = %{version}-%{release}
+Provides: %{?scl_prefix}php-pecl-%{pecl_name}%{?_isa} = %{version}-%{release}
%if "%{?vendor}" == "Remi Collet" && 0%{!?scl:1}
# Other third party repo stuff
@@ -108,7 +107,7 @@ Provides: %{?scl_prefix}php-%{extname}-devel%{?_isa} = %{version}-%{release
%description devel
These are the files needed to compile programs using Igbinary
-Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')%{?scl: as Software Collection (%{scl})}.
+Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')%{?scl: as Software Collection (%{scl} by %{?scl_vendor}%{!?scl_vendor:rh})}.
%prep
@@ -122,6 +121,8 @@ sed -e '/release/s/-dev/dev/' -i package.xml
mv %{extname}-%{version} NTS
%endif
+%{?_licensedir:sed -e '/LICENSE/s/role="doc"/role="src"/' -i package.xml}
+
cd NTS
# Check version
@@ -232,6 +233,7 @@ REPORT_EXIT_STATUS=1 \
rm -rf %{buildroot}
+%if 0%{?fedora} < 24
# when pear installed alone, after us
%triggerin -- %{?scl_prefix}php-pear
if [ -x %{__pecl} ] ; then
@@ -248,10 +250,12 @@ fi
if [ $1 -eq 0 -a -x %{__pecl} ] ; then
%{pecl_uninstall} %{extname} >/dev/null || :
fi
+%endif
%files
%defattr(-,root,root,-)
+%{?_licensedir:%license NTS/COPYING}
%doc %{pecl_docdir}/%{extname}
%config(noreplace) %{php_inidir}/%{ini_name}
diff --git a/php-pecl-igbinary.spec b/php-pecl-igbinary.spec
index b1138b5..cf01cb2 100644
--- a/php-pecl-igbinary.spec
+++ b/php-pecl-igbinary.spec
@@ -18,14 +18,11 @@
%endif
%{?scl: %scl_package php-pecl-igbinary}
-%{!?php_inidir: %global php_inidir %{_sysconfdir}/php.d}
-%{!?__pecl: %global __pecl %{_bindir}/pecl}
-%{!?__php: %global __php %{_bindir}/php}
%global extname igbinary
%global with_zts 0%{?__ztsphp:1}
#global commit c35d48f3d14794373b2ef89a6d79020bb7418d7f
-#global short %(c=%{commit}; echo ${c:0:7})
+#global short %%(c=%%{commit}; echo ${c:0:7})
#global prever -dev
%if "%{php_version}" < "5.6"
%global ini_name %{extname}.ini
@@ -62,6 +59,8 @@ Provides: %{?scl_prefix}php-%{extname} = %{version}
Provides: %{?scl_prefix}php-%{extname}%{?_isa} = %{version}
Provides: %{?scl_prefix}php-pecl(%{extname}) = %{version}
Provides: %{?scl_prefix}php-pecl(%{extname})%{?_isa} = %{version}
+Provides: %{?scl_prefix}php-pecl-%{pecl_name} = %{version}-%{release}
+Provides: %{?scl_prefix}php-pecl-%{pecl_name}%{?_isa} = %{version}-%{release}
%if "%{?vendor}" == "Remi Collet" && 0%{!?scl:1}
# Other third party repo stuff
@@ -108,7 +107,7 @@ Provides: %{?scl_prefix}php-%{extname}-devel%{?_isa} = %{version}-%{release
%description devel
These are the files needed to compile programs using Igbinary
-Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')%{?scl: as Software Collection (%{scl})}.
+Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')%{?scl: as Software Collection (%{scl} by %{?scl_vendor}%{!?scl_vendor:rh})}.
%prep
@@ -122,6 +121,8 @@ sed -e '/release/s/-dev/dev/' -i package.xml
mv %{extname}-%{version} NTS
%endif
+%{?_licensedir:sed -e '/LICENSE/s/role="doc"/role="src"/' -i package.xml}
+
cd NTS
# Check version
@@ -232,6 +233,7 @@ REPORT_EXIT_STATUS=1 \
rm -rf %{buildroot}
+%if 0%{?fedora} < 24
# when pear installed alone, after us
%triggerin -- %{?scl_prefix}php-pear
if [ -x %{__pecl} ] ; then
@@ -248,10 +250,12 @@ fi
if [ $1 -eq 0 -a -x %{__pecl} ] ; then
%{pecl_uninstall} %{extname} >/dev/null || :
fi
+%endif
%files
%defattr(-,root,root,-)
+%{?_licensedir:%license NTS/COPYING}
%doc %{pecl_docdir}/%{extname}
%config(noreplace) %{php_inidir}/%{ini_name}