Sophie

Sophie

distrib > Mageia > 9 > armv7hl > media > core-release-src > by-pkgid > 56f0fd44e4be7c6f13d3868bb303bdf6 > files > 2

php-pear-Image_Text-0.7.0-10.mga9.src.rpm

%define		_class		Image
%define		_subclass	Text
%define		upstream_name	%{_class}_%{_subclass}
%define peardir %(pear config-get php_dir 2> /dev/null || echo %{_datadir}/pear)
%define xmldir  /var/lib/pear


Name:		php-pear-%{upstream_name}
Version:	0.7.0
Release:	%mkrel 10
Summary:	Image_Text - Advanced text manipulations in images
License:	PHP License
Group:		Development/PHP
URL:		https://pear.php.net/package/Image_Text/
Source0: 	https://pear.php.net/get/%{upstream_name}-%{version}.tgz
BuildRequires:	php-pear >= 1.4.7
BuildArch:	noarch


%description
Image_Text provides a comfortable interface to text manipulations in GD
images. Beside common Freetype2 functionality it offers to handle texts
in a graphic- or office-tool like way. For example it allows alignment of
texts inside a text box, rotation (around the top left corner of a text
box or it's center point) and the automatic measurement of the optimal
font size for a given text box.

%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
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

mv %{buildroot}/docs .


# Install XML package description
mkdir -p %{buildroot}%{xmldir}
tar -xzf %{SOURCE0} package.xml
cp -p package.xml %{buildroot}%{xmldir}/Image_Text.xml

%post
pear install --nodeps --soft --force --register-only %{xmldir}/Image_Text.xml

%postun
if [ "$1" -eq "0" ]; then
    pear uninstall --nodeps --ignore-errors --register-only pear.php.net/Image_Text
fi

%files
%doc docs/Image_Text/*
%{peardir}/*
%{xmldir}/Image_Text.xml


%changelog
* Tue Mar 22 2022 umeabot <umeabot> 0.7.0-10.mga9
+ Revision: 1817809
- Mageia 9 Mass Rebuild

* Wed Feb 12 2020 umeabot <umeabot> 0.7.0-9.mga8
+ Revision: 1499064
- Mageia 8 Mass Rebuild

* Wed Sep 19 2018 umeabot <umeabot> 0.7.0-8.mga7
+ Revision: 1273284
- Mageia 7 Mass Rebuild

* Fri Feb 05 2016 umeabot <umeabot> 0.7.0-7.mga6
+ Revision: 937583
- Mageia 6 Mass Rebuild

* Fri Feb 05 2016 umeabot <umeabot> 0.7.0-6.mga6
+ Revision: 937154
- Mageia 6 Mass Rebuild

* Wed Oct 15 2014 umeabot <umeabot> 0.7.0-5.mga5
+ Revision: 750132
- Second Mageia 5 Mass Rebuild

* Wed Oct 01 2014 tv <tv> 0.7.0-4.mga5
+ Revision: 734053
- rebuild for pear deps

* Tue Sep 16 2014 umeabot <umeabot> 0.7.0-3.mga5
+ Revision: 687317
- Mageia 5 Mass Rebuild

* Mon Oct 21 2013 umeabot <umeabot> 0.7.0-2.mga4
+ Revision: 538530
- Mageia 4 Mass Rebuild

* Tue Oct 01 2013 spuhler <spuhler> 0.7.0-1.mga4
+ Revision: 489901
- upgrade to vers. 0.7.0

* Sat Jun 15 2013 spuhler <spuhler> 0.6.1-1.mga4
+ Revision: 443360
- upgrade to version 0.6.1
- pearized spec file

* Sun Jan 13 2013 umeabot <umeabot> 0.5.0-13.mga3
+ Revision: 376774
- Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild

* Sat Feb 05 2011 spuhler <spuhler> 0.5.0-12.mga1
+ Revision: 47491
- removed buildroot definition from .spec
  removed the if mdkversion lines
- imported package php-pear-Image_Text