Search
j0ke.net Open Build Service
>
Projects
>
internetx
:
php5
:
EL5
:
5.3.20
:
extensions
>
php-pecl-xhprof
> php-pecl-xhprof.spec
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File php-pecl-xhprof.spec of Package php-pecl-xhprof
%global php_apiver %((echo 0; php -i 2>/dev/null | sed -n 's/^PHP API => //p') | tail -1) %{!?__pecl: %{expand: %%global __pecl %{_bindir}/pecl}} %{!?php_extdir: %{expand: %%global php_extdir %(php-config --extension-dir)}} %define pecl_name xhprof Name: php-pecl-xhprof Version: 0.9.3 Release: 1 Summary: PECL package for debugging PHP scripts License: BSD Group: Development/Languages URL: http://pecl.php.net/package/xhprof Source0: http://pecl.php.net/get/xhprof-%{version}.tgz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: automake php-devel php-pear >= 1:1.4.9-1.2 #BuildRequires: libedit-devel %define config_flags --without-libedit Requires(post): %{__pecl} Requires(postun): %{__pecl} Provides: php-pecl(Xhprof) = %{version} %if %{defined php_zend_api} Requires: php(zend-abi) = %{php_zend_api} Requires: php(api) = %{php_core_api} %else Requires: php-api = %{php_apiver} %endif %description %prep %setup -n %{pecl_name}-%{version} cd .. [ -f package2.xml ] || mv package.xml package2.xml mv package2.xml %{pecl_name}-%{version}/%{pecl_name}.xml cd %{pecl_name}-%{version} %build pushd extension phpize %configure --enable-xhprof CFLAGS="$RPM_OPT_FLAGS" make popd %install pushd extension rm -rf $RPM_BUILD_ROOT %__make install INSTALL_ROOT=$RPM_BUILD_ROOT popd # install config file install -d $RPM_BUILD_ROOT%{_sysconfdir}/php.d cat > $RPM_BUILD_ROOT%{_sysconfdir}/php.d/xhprof.ini << 'EOF' ; Enable xhprof extension module extension=xhprof.so EOF # install doc files install -d docs install -pm 644 CHANGELOG CREDITS LICENSE README docs # Install XML package description install -d $RPM_BUILD_ROOT%{pecl_xmldir} install -pm 644 %{pecl_name}.xml $RPM_BUILD_ROOT%{pecl_xmldir}/%{name}.xml %if 0%{?pecl_install:1} %post %{pecl_install} %{pecl_xmldir}/%{name}.xml >/dev/null || : %endif %if 0%{?pecl_uninstall:1} %postun if [ $1 -eq 0 ] ; then %{pecl_uninstall} %{pecl_name} >/dev/null || : fi %endif %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root,-) %doc docs/* %config(noreplace) %{_sysconfdir}/php.d/xhprof.ini %{php_extdir}/xhprof.so %{pecl_xmldir}/%{name}.xml %changelog * Thu Apr 14 2011 Carsten Schoene <cs@linux-administrator.com> - 0.9.2-1 - initial bs import