Sophie

Sophie

distrib > Arklinux > devel > x86_64 > media > main-src > by-pkgid > 556a314e52a2606a1f23c4aef5104f29 > files > 2

ttfonts-ar-1.1-1ark.src.rpm

%define	xfontdir_	%{_datadir}/fonts/ar
%define	xfontdir	%{xfontdir_}/TrueType

Summary:	TrueType Fonts for Arabic
Name:		ttfonts-ar
Version:	1.1
Release:	1ark
License:	GPL
Group:		Internationalization/Arabic
BuildArch:	noarch
BuildRoot:	%{_tmppath}/%{name}-%{version}-root

URL:		http://www.arabeyes.org/
Source:		http://heanet.dl.sourceforge.net/sourceforge/arabeyes/ae_fonts1_ttf_%version.tar.bz2

Requires(post,postun): %_bindir/mkfontdir /usr/sbin/chkfontpath
Requires(post,postun): fontconfig

%description
Arabic TrueType Fonts

%prep
%setup -q -n ae_fonts1-%version

%build
mkdir -p %{name}-%{version}/doc

%install
[ -n "$RPM_BUILD_ROOT" -a "$RPM_BUILD_ROOT" != / ] && rm -rf $RPM_BUILD_ROOT

install -d $RPM_BUILD_ROOT%{xfontdir}
install -m 0644 */*.ttf $RPM_BUILD_ROOT%{xfontdir}/

%clean
[ -n "$RPM_BUILD_ROOT" -a "$RPM_BUILD_ROOT" != / ] && rm -rf $RPM_BUILD_ROOT

%post
{
	umask 133
	touch %{xfontdir} 2> /dev/null && {
		%_bindir/mkfontscale %{xfontdir}
		%_bindir/mkfontdir %{xfontdir}
		/usr/sbin/chkfontpath -q -a %{xfontdir}
	}

	#Update fontconfig cache
	[  -x /usr/bin/fc-cache ] && HOME=/root /usr/bin/fc-cache %{xfontdir} 2> /dev/null
}

%postun
if [ "$1" = 0 ];
then
    umask 133
    /usr/sbin/chkfontpath -q -r %{xfontdir}
    #Update fontconfig cache
    [ -x /usr/bin/fc-cache ] && HOME=/root /usr/bin/fc-cache %{xfontdir} 2> /dev/null
fi

%files
%defattr(-, root, root, -)
%doc $RPM_BUILD_DIR/%{name}-%{version}/doc/
%attr(0755, root, root) %dir %{xfontdir_}
%attr(0755, root, root) %dir %{xfontdir}
%{xfontdir}/*ttf

%changelog
* Thu Jan 26 2006 Bernhard Rosenkraenzer <bero@arklinux.org> 1.1-1ark
- 1.1
- mkfontscale lives in %_bindir these days

* Mon Dec 20 2004 Bernhard Rosenkraenzer <bero@arklinux.org> 1.0-2ark
- Use mkfontscale instead of ttmkfdir

* Tue Jun  8 2004 Bernhard Rosenkraenzer <bero@arklinux.org> 1.0-1ark
- Initial rpm