Blob Blame History Raw
Name:           t1lib
Version:        5.0.2
Release: 3

Summary:        PostScript Type 1 font rasterizer

Group:          Applications/Publishing
License:        LGPL
URL:            ftp://sunsite.unc.edu/pub/Linux/libs/graphics
Source0:        ftp://sunsite.unc.edu/pub/Linux/libs/graphics/t1lib-5.0.2.tar.gz
# Based on patches in Mandrakes's t1lib-1.3.1-9mdk.src.rpm:
Patch0:         t1lib-5.0.0-install.patch
# From Debian's t1lib-5.0.0-4:
Patch1:         t1lib-5.0.0-manpages.patch
Patch2:         t1lib-5.0.0-xglyph-env.patch
Patch3:         t1lib-5.0.0-hintfix.patch
# From Debian's t1lib-5.0.0-4 (slightly tweaked):
Patch5:         t1lib-5.0.0-t1libconfig.patch
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

BuildRequires:  XFree86-devel
BuildRequires:  autoconf
BuildRequires:  perl

%description
T1lib is a rasterizer library for Adobe Type 1 Fonts. It supports
rotation and transformation, kerning underlining and antialiasing. It
does not depend on X11, but does provides some special functions for
X11.

AFM-files can be generated from Type 1 font files and font subsetting
is possible.

%package        devel
Summary:        Header files and static libraries for %{name}
Group:          Development/Libraries
Requires:       %{name} = %{version}-%{release}

%description    devel
This package contains header files and static libraries for %{name}.


%prep
%setup -q
%patch0 -p1 -b .install
%patch1 -p1
%patch2 -p1
%patch5 -p1


%build
perl -pi -e 's/^dbl$$//' configure.in
autoconf
%configure
make %{?_smp_mflags} without_doc
ln README.t1lib-5.0.2 README

%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
find $RPM_BUILD_ROOT -type f -name "*.la" -exec rm -f {} ';'

mkdir -p $RPM_BUILD_ROOT%{_mandir}/man{1,5,8}
install -p -m 644 debian/FontDatabase.5 $RPM_BUILD_ROOT%{_mandir}/man5/
install -p -m 644 debian/t1libconfig.8 $RPM_BUILD_ROOT%{_mandir}/man8/
install -p -m 644 debian/type1afm.1 $RPM_BUILD_ROOT%{_mandir}/man1/
install -p -m 644 debian/xglyph.1 $RPM_BUILD_ROOT%{_mandir}/man1/

mkdir -p $RPM_BUILD_ROOT%{_sbindir}
install -p -m 755 debian/t1libconfig $RPM_BUILD_ROOT%{_sbindir}/

touch FontDatabase
install -p -m 644 FontDatabase $RPM_BUILD_ROOT%{_sysconfdir}/t1lib/


%clean
rm -rf $RPM_BUILD_ROOT


%post
/sbin/ldconfig
if [ "$1" = "1" ]; then
  /usr/sbin/t1libconfig --force > /dev/null
fi

%postun -p /sbin/ldconfig


%files
%defattr(-,root,root,-)
%doc Changes LGPL LICENSE README
%dir %{_sysconfdir}/t1lib
%config %{_sysconfdir}/t1lib/t1lib.config
%config %{_sysconfdir}/t1lib/FontDatabase
%{_bindir}/*
%{_libdir}/*.so.*
%{_mandir}/man[^3]/*
%{_sbindir}/*

%files devel
%defattr(-,root,root,-)
%doc doc/t1lib_doc.pdf
%{_includedir}/*
%{_libdir}/*.a
%{_libdir}/*.so


%changelog
* Sun May 22 2005 Jeremy Katz <katzj@redhat.com> - 5.0.2-3
- rebuild on all arches

* Fri Apr  7 2005 Michael Schwendt <mschwendt[AT]users.sf.net>
- rebuilt

* Thu Mar 11 2004 Marius L. Jøhndal <mariuslj at ifi.uio.no> - 0:5.0.2-0.fdr.1
- Updated to 5.0.2.

* Sat Feb  7 2004 Marius L. Jøhndal <mariuslj at ifi.uio.no> 0:5.0.0-0.fdr.3
- Converted spec file to UTF-8.
- Synchronised patches with Debian (unstable) t1lib-5.0.0.

* Thu Nov 27 2003 Marius L. Jøhndal <mariuslj at ifi.uio.no> 0:5.0.0-0.fdr.2
- Added URL (bug 880).
- Eliminated funny typo in configure script (bug 880).

* Sun Oct 26 2003 Marius L. Jøhndal <mariuslj at ifi.uio.no> 0:5.0.0-0.fdr.1
- Initial RPM release.