From b2727e93a1ea643d98d5433d1670eac46c6b3b04 Mon Sep 17 00:00:00 2001 From: Tim Waugh Date: Wed, 13 Jul 2005 13:29:37 +0000 Subject: [PATCH] - Split font configuration (bug #161187). --- FAPIcidfmap | 8 ++++++++ ghostscript.spec | 26 ++++++++++++++++++++++---- 2 files changed, 30 insertions(+), 4 deletions(-) create mode 100644 FAPIcidfmap diff --git a/FAPIcidfmap b/FAPIcidfmap new file mode 100644 index 0000000..1be79e7 --- /dev/null +++ b/FAPIcidfmap @@ -0,0 +1,8 @@ +%! +% Don't change following line. We should ensure that the original one is surely loaded. +(FAPIcidfmap.GS) .runlibfile +% following lines are for CJK fonts. +(FAPIcidfmap.ja) .runlibfileifexists +(FAPIcidfmap.ko) .runlibfileifexists +(FAPIcidfmap.zh_CN) .runlibfileifexists +(FAPIcidfmap.zh_TW) .runlibfileifexists diff --git a/ghostscript.spec b/ghostscript.spec index 4f2c1a7..ef3197f 100644 --- a/ghostscript.spec +++ b/ghostscript.spec @@ -11,6 +11,7 @@ License: GPL URL: http://www.cups.org/espgs/ Group: Applications/Publishing Source0: ftp://ftp.rz.tu-bs.de/pub/mirror/ftp.easysw.com/ftp/pub/ghostscript/%{?gs_rc:test/}espgs-%{gs_ver}%{gs_rc}-source.tar.bz2 +Source1: FAPIcidfmap Patch1: ghostscript-build.patch Patch2: ghostscript-gtk2.patch @@ -20,7 +21,7 @@ Patch5: ghostscript-badc.patch Patch6: ghostscript-pagesize.patch Patch7: ghostscript-noopt.patch Patch8: ghostscript-use-external-freetype.patch -Patch9: ghostscript-japanese-fonts.patch +Patch9: ghostscript-split-font-configuration.patch Requires: zlib, libpng, glib2 Requires: urw-fonts >= 1.1, ghostscript-fonts @@ -94,8 +95,8 @@ A GTK-enabled version of Ghostscript, called 'gsx'. # Use external freetype (bug #161187). %patch8 -p1 -b .use-external-freetype -# Add Japanese fonts to FAPIcidfmap (bug #161187). -%patch9 -p1 -b .japanese-fonts +# Allow separated font configuration (bug #161187). +%patch9 -p1 -b .split-font-configuration # Convert manual pages to UTF-8 from8859_1() { @@ -105,7 +106,17 @@ from8859_1() { for i in man/de/*.1; do from8859_1 "$i"; done %build -%configure --with-ijs --enable-dynamic +FONTPATH= +for path in \ + %{_datadir}/fonts/default/%{name} \ + %{_datadir}/fonts/default/Type1 \ + %{_datadir}/fonts/default/amspsfnt/pfb \ + %{_datadir}/fonts/default/cmpsfont/pfb \ + %{_sysconfdir}/%{name} +do + FONTPATH="$FONTPATH${FONTPATH:+:}$path" +done +%configure --with-ijs --enable-dynamic --with-fontpath="$FONTPATH" # Build IJS cd ijs @@ -150,6 +161,12 @@ cd .. ln -sf gs.1.gz $RPM_BUILD_ROOT/%{_mandir}/man1/ghostscript.1.gz ln -sf gs $RPM_BUILD_ROOT/usr/bin/ghostscript +# Rename an original FAPIcidfmap to FAPIcidfmap.GS +mv $RPM_BUILD_ROOT%{_datadir}/%{name}/%{gs_ver}/lib/FAPIcidfmap{,.GS} +# Install our own FAPIcidfmap to allow the separated +# FAPIcidfmap which the font packages own. +install -m0644 %{SOURCE1} $RPM_BUILD_ROOT%{_datadir}/%{name}/%{gs_ver}/lib/FAPIcidfmap + # Don't ship sysvlp.sh. rm -f $RPM_BUILD_ROOT/usr/bin/sysvlp.sh @@ -227,6 +244,7 @@ rm -rf $RPM_BUILD_ROOT %changelog * Wed Jul 13 2005 Tim Waugh +- Split font configuration (bug #161187). - Reverted this change: - Build requires xorg-x11-devel, not XFree86-devel.