%define upstream_name Services_Yahoo %define xmldir %{_var}/lib/pear %define peardir %(pear config-get php_dir 2> /dev/null) Name: php-pear-%{upstream_name} Version: 0.2.0 Release: %mkrel 2 Summary: Provides access to the Yahoo! Web Services License: PHP License Group: Development/PHP Source0: http://pear.php.net/get/Services_Yahoo-%{version}.tgz URL: http://pear.php.net/package/Services_Yahoo BuildRequires: php-pear >= 1.4.7 BuildArch: noarch %description Provides access to the Yahoo! Web Services %prep %setup -c -T pear -v -c pearrc \ -d php_dir=%{peardir} \ -d doc_dir=/docs \ -d bin_dir=%{_bindir} \ -d data_dir=%{peardir}/data \ -d test_dir=%{peardir}/tests \ -d ext_dir=%{_libdir} \ -s %build %install rm -rf %{buildroot} pear -c pearrc install --nodeps --packagingroot %{buildroot} %{SOURCE0} # Clean up unnecessary files rm pearrc rm %{buildroot}/%{peardir}/.filemap rm %{buildroot}/%{peardir}/.lock rm -rf %{buildroot}/%{peardir}/.registry rm -rf %{buildroot}%{peardir}/.channels rm %{buildroot}%{peardir}/.depdb rm %{buildroot}%{peardir}/.depdblock # Install XML package description mkdir -p %{buildroot}%{xmldir} tar -xzf %{SOURCE0} package.xml cp -p package.xml %{buildroot}%{xmldir}/Services_Yahoo.xml mkdir %{buildroot}%{peardir}/tests/Services mv %{buildroot}%{peardir}/tests/Services_Yahoo/* %{buildroot}%{peardir}/tests/Services %post pear install --nodeps --soft --force --register-only %{xmldir}/Services_Yahoo.xml %postun if [ "$1" -eq "0" ]; then pear uninstall --nodeps --ignore-errors --register-only pear.php.net/Services_Yahoo fi %files %{peardir}/* %{xmldir}/Services_Yahoo.xml %changelog * Sun Jan 13 2013 umeabot <umeabot> 0.2.0-2.mga3 + Revision: 377289 - Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild * Fri Oct 26 2012 neoclust <neoclust> 0.2.0-1.mga3 + Revision: 310172 - imported package php-pear-Services_Yahoo