From 00fdb4aed3367333cbb66b16e7c0e9147fdd9a9f Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Sat, 15 Mar 2014 09:00:42 +0100 Subject: php-pecl-xhprof: cleanups --- php-pecl-xhprof.spec | 81 +++++++++++++++++++++++++++++++++++++++------------- 1 file changed, 61 insertions(+), 20 deletions(-) diff --git a/php-pecl-xhprof.spec b/php-pecl-xhprof.spec index c0ff2fa..5f89e8b 100644 --- a/php-pecl-xhprof.spec +++ b/php-pecl-xhprof.spec @@ -6,13 +6,16 @@ # # Please, preserve the changelog entries # -%{!?__pecl: %{expand: %%global __pecl %{_bindir}/pecl}} +%{!?php_inidir: %global php_inidir %{_sysconfdir}/php.d} +%{!?__pecl: %global __pecl %{_bindir}/pecl} +%{!?__php: %global __php %{_bindir}/php} %global pecl_name xhprof +%global with_zts 0%{?__ztsphp:1} Name: php-pecl-xhprof Version: 0.9.4 -Release: 1%{?gitver:.git%{gitver}}%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')} +Release: 2%{?gitver:.git%{gitver}}%{?dist}%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')} Summary: PHP extension for XHProf, a Hierarchical Profiler Group: Development/Languages @@ -45,9 +48,24 @@ Obsoletes: php54-pecl-%{pecl_name} Obsoletes: php55u-pecl-%{pecl_name} %endif -# Filter private provides +%if "%{?vendor}" == "Remi Collet" +# Other third party repo stuff +Obsoletes: php53-pecl-%{pecl_name} +Obsoletes: php53u-pecl-%{pecl_name} +Obsoletes: php54-pecl-%{pecl_name} +%if "%{php_version}" > "5.5" +Obsoletes: php55u-pecl-%{pecl_name} +%endif +%if "%{php_version}" > "5.6" +Obsoletes: php56u-pecl-%{pecl_name} +%endif +%endif + +%if 0%{?fedora} < 20 +# Filter private shared object %{?filter_provides_in: %filter_provides_in %{_libdir}/.*\.so$} %{?filter_setup} +%endif %description @@ -84,18 +102,16 @@ for each function. Additionally, it supports ability to compare two runs (hierarchical DIFF reports), or aggregate results from multiple runs. -%if "%{?_pkgdocdir}" == "%{_docdir}/%{name}" -Documentation : %{_docdir}/xhprof/index.html -%else -Documentation : %{_docdir}/xhprof-%{version}/index.html -%endif +Documentation: %{pecl_docdir}/%{pecl_name}/xhprof_html/docs/index.html %prep %setup -c -q -# All files as src to avoid registration in pear file list -sed -e 's/role="[a-z]*"/role="src"/' -i package.xml +# Mark "php" files as "src" to avoid registration in pear file list +# xhprof_html should be web, but www_dir is /var/www/html +# xhprof_lib should be php, really a lib +sed -e 's/role="php"/role="src"/' -i package.xml # Extension configuration file cat >%{pecl_name}.ini < - 0.9.4-2 +- install doc in pecl_docdir +- install test in pecl_testdir + * Tue Oct 1 2013 Remi Collet - 0.9.4-1 - update to 0.9.4 -- cgit