1 |
dilfridge 12/05/01 22:43:34 |
2 |
|
3 |
Modified: ChangeLog |
4 |
Added: ghostscript-gpl-9.05-r1.ebuild |
5 |
Log: |
6 |
Add symlink for poppler-data integration, bug 409361 |
7 |
|
8 |
(Portage version: 2.2.0_alpha101/cvs/Linux x86_64) |
9 |
|
10 |
Revision Changes Path |
11 |
1.138 app-text/ghostscript-gpl/ChangeLog |
12 |
|
13 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/ghostscript-gpl/ChangeLog?rev=1.138&view=markup |
14 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/ghostscript-gpl/ChangeLog?rev=1.138&content-type=text/plain |
15 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/ghostscript-gpl/ChangeLog?r1=1.137&r2=1.138 |
16 |
|
17 |
Index: ChangeLog |
18 |
=================================================================== |
19 |
RCS file: /var/cvsroot/gentoo-x86/app-text/ghostscript-gpl/ChangeLog,v |
20 |
retrieving revision 1.137 |
21 |
retrieving revision 1.138 |
22 |
diff -u -r1.137 -r1.138 |
23 |
--- ChangeLog 26 Apr 2012 21:11:46 -0000 1.137 |
24 |
+++ ChangeLog 1 May 2012 22:43:34 -0000 1.138 |
25 |
@@ -1,6 +1,12 @@ |
26 |
# ChangeLog for app-text/ghostscript-gpl |
27 |
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 |
28 |
-# $Header: /var/cvsroot/gentoo-x86/app-text/ghostscript-gpl/ChangeLog,v 1.137 2012/04/26 21:11:46 aballier Exp $ |
29 |
+# $Header: /var/cvsroot/gentoo-x86/app-text/ghostscript-gpl/ChangeLog,v 1.138 2012/05/01 22:43:34 dilfridge Exp $ |
30 |
+ |
31 |
+*ghostscript-gpl-9.05-r1 (01 May 2012) |
32 |
+ |
33 |
+ 01 May 2012; Andreas K. Huettel <dilfridge@g.o> |
34 |
+ +ghostscript-gpl-9.05-r1.ebuild: |
35 |
+ Add symlink for poppler-data integration, bug 409361 |
36 |
|
37 |
26 Apr 2012; Alexis Ballier <aballier@g.o> |
38 |
ghostscript-gpl-9.05.ebuild: |
39 |
|
40 |
|
41 |
|
42 |
1.1 app-text/ghostscript-gpl/ghostscript-gpl-9.05-r1.ebuild |
43 |
|
44 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/ghostscript-gpl/ghostscript-gpl-9.05-r1.ebuild?rev=1.1&view=markup |
45 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/ghostscript-gpl/ghostscript-gpl-9.05-r1.ebuild?rev=1.1&content-type=text/plain |
46 |
|
47 |
Index: ghostscript-gpl-9.05-r1.ebuild |
48 |
=================================================================== |
49 |
# Copyright 1999-2012 Gentoo Foundation |
50 |
# Distributed under the terms of the GNU General Public License v2 |
51 |
# $Header: /var/cvsroot/gentoo-x86/app-text/ghostscript-gpl/ghostscript-gpl-9.05-r1.ebuild,v 1.1 2012/05/01 22:43:34 dilfridge Exp $ |
52 |
|
53 |
EAPI=3 |
54 |
|
55 |
inherit autotools eutils versionator flag-o-matic |
56 |
|
57 |
DESCRIPTION="Ghostscript is an interpreter for the PostScript language and for PDF" |
58 |
HOMEPAGE="http://ghostscript.com/" |
59 |
|
60 |
MY_P=${P/-gpl} |
61 |
GSDJVU_PV=1.5 |
62 |
PVM=$(get_version_component_range 1-2) |
63 |
SRC_URI=" |
64 |
mirror://sourceforge/ghostscript/${MY_P}.tar.bz2 |
65 |
mirror://gentoo/${P}-patchset-1.tar.bz2 |
66 |
!bindist? ( djvu? ( mirror://sourceforge/djvu/gsdjvu-${GSDJVU_PV}.tar.gz ) )" |
67 |
|
68 |
LICENSE="GPL-3 CPL-1.0" |
69 |
SLOT="0" |
70 |
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd" |
71 |
IUSE="bindist cups dbus djvu gtk idn jpeg2k static-libs X" |
72 |
|
73 |
COMMON_DEPEND=" |
74 |
app-text/libpaper |
75 |
media-libs/fontconfig |
76 |
>=media-libs/freetype-2.4.2:2 |
77 |
media-libs/jbig2dec |
78 |
media-libs/lcms:2 |
79 |
media-libs/libpng:0 |
80 |
media-libs/tiff:0 |
81 |
>=sys-libs/zlib-1.2.3 |
82 |
virtual/jpeg |
83 |
!bindist? ( djvu? ( app-text/djvu ) ) |
84 |
cups? ( >=net-print/cups-1.3.8 ) |
85 |
dbus? ( sys-apps/dbus ) |
86 |
gtk? ( x11-libs/gtk+:2 ) |
87 |
idn? ( net-dns/libidn ) |
88 |
jpeg2k? ( media-libs/jasper ) |
89 |
X? ( x11-libs/libXt x11-libs/libXext )" |
90 |
|
91 |
DEPEND="${COMMON_DEPEND} |
92 |
dev-util/pkgconfig" |
93 |
|
94 |
RDEPEND="${COMMON_DEPEND} |
95 |
>=app-text/poppler-data-0.4.5-r1 |
96 |
>=media-fonts/urw-fonts-2.4.9 |
97 |
linguas_ja? ( media-fonts/kochi-substitute ) |
98 |
linguas_ko? ( media-fonts/baekmuk-fonts ) |
99 |
linguas_zh_CN? ( media-fonts/arphicfonts ) |
100 |
linguas_zh_TW? ( media-fonts/arphicfonts ) |
101 |
!!media-fonts/gnu-gs-fonts-std |
102 |
!!media-fonts/gnu-gs-fonts-other |
103 |
" |
104 |
|
105 |
S="${WORKDIR}/${MY_P}" |
106 |
|
107 |
LANGS="ja ko zh_CN zh_TW" |
108 |
for X in ${LANGS} ; do |
109 |
IUSE="${IUSE} linguas_${X}" |
110 |
done |
111 |
|
112 |
pkg_setup() { |
113 |
if use bindist && use djvu; then |
114 |
ewarn "You have bindist in your USE, djvu support will NOT be compiled!" |
115 |
ewarn "See http://djvu.sourceforge.net/gsdjvu/COPYING for details on licensing issues." |
116 |
fi |
117 |
} |
118 |
|
119 |
src_prepare() { |
120 |
# remove internal copies of various libraries |
121 |
rm -rf "${S}"/expat |
122 |
rm -rf "${S}"/freetype |
123 |
rm -rf "${S}"/jasper |
124 |
rm -rf "${S}"/jbig2dec |
125 |
rm -rf "${S}"/jpeg |
126 |
rm -rf "${S}"/lcms{,2} |
127 |
rm -rf "${S}"/libpng |
128 |
rm -rf "${S}"/openjpeg |
129 |
rm -rf "${S}"/tiff |
130 |
rm -rf "${S}"/zlib |
131 |
# remove internal urw-fonts |
132 |
rm -rf "${S}"/Resource/Font |
133 |
# remove internal CMaps (CMaps from poppler-data are used instead) |
134 |
rm -rf "${S}"/Resource/CMap |
135 |
|
136 |
# apply various patches, many borrowed from Fedora |
137 |
# http://pkgs.fedoraproject.org/gitweb/?p=ghostscript.git |
138 |
EPATCH_SUFFIX="patch" EPATCH_FORCE="yes" |
139 |
EPATCH_SOURCE="${WORKDIR}/patches/" |
140 |
epatch |
141 |
|
142 |
if ! use bindist && use djvu ; then |
143 |
unpack gsdjvu-${GSDJVU_PV}.tar.gz |
144 |
cp gsdjvu-${GSDJVU_PV}/gsdjvu "${S}" |
145 |
cp gsdjvu-${GSDJVU_PV}/gdevdjvu.c "${S}/base" |
146 |
epatch "${WORKDIR}/patches-gsdjvu/gsdjvu-1.3-${PN}-8.64.patch" |
147 |
epatch "${WORKDIR}/patches-gsdjvu/gsdjvu-1.5-${PN}-9.05.patch" |
148 |
cp gsdjvu-${GSDJVU_PV}/ps2utf8.ps "${S}/lib" |
149 |
cp "${S}/base/contrib.mak" "${S}/base/contrib.mak.gsdjvu" |
150 |
grep -q djvusep "${S}/base/contrib.mak" || \ |
151 |
cat gsdjvu-${GSDJVU_PV}/gsdjvu.mak >> "${S}/base/contrib.mak" |
152 |
|
153 |
# install ps2utf8.ps, bug #197818 |
154 |
sed -i -e '/$(EXTRA_INIT_FILES)/ a\ps2utf8.ps \\' "${S}/base/unixinst.mak" \ |
155 |
|| die "sed failed" |
156 |
fi |
157 |
|
158 |
if ! use gtk ; then |
159 |
sed -i "s:\$(GSSOX)::" base/*.mak || die "gsx sed failed" |
160 |
sed -i "s:.*\$(GSSOX_XENAME)$::" base/*.mak || die "gsxso sed failed" |
161 |
fi |
162 |
|
163 |
# search path fix |
164 |
sed -i -e "s:\$\(gsdatadir\)/lib:/usr/share/ghostscript/${PVM}/$(get_libdir):" \ |
165 |
-e "s:exdir=.*:exdir=/usr/share/doc/${PF}/examples:" \ |
166 |
-e "s:docdir=.*:docdir=/usr/share/doc/${PF}/html:" \ |
167 |
-e "s:GS_DOCDIR=.*:GS_DOCDIR=/usr/share/doc/${PF}/html:" \ |
168 |
-e 's:-L$(BINDIR):$(LDFLAGS) &:g' \ |
169 |
base/Makefile.in base/*.mak || die "sed failed" |
170 |
|
171 |
cd "${S}" |
172 |
eautoreconf |
173 |
|
174 |
cd "${S}/ijs" |
175 |
eautoreconf |
176 |
} |
177 |
|
178 |
src_configure() { |
179 |
local FONTPATH |
180 |
for path in \ |
181 |
/usr/share/fonts/urw-fonts \ |
182 |
/usr/share/fonts/Type1 \ |
183 |
/usr/share/fonts \ |
184 |
/usr/share/poppler/cMap/Adobe-CNS1 \ |
185 |
/usr/share/poppler/cMap/Adobe-GB1 \ |
186 |
/usr/share/poppler/cMap/Adobe-Japan1 \ |
187 |
/usr/share/poppler/cMap/Adobe-Japan2 \ |
188 |
/usr/share/poppler/cMap/Adobe-Korea1 |
189 |
do |
190 |
FONTPATH="$FONTPATH${FONTPATH:+:}$path" |
191 |
done |
192 |
|
193 |
econf \ |
194 |
--enable-dynamic \ |
195 |
--enable-freetype \ |
196 |
--enable-fontconfig \ |
197 |
--disable-compile-inits \ |
198 |
--disable-openjpeg \ |
199 |
--with-drivers=ALL \ |
200 |
--with-fontpath="$FONTPATH" \ |
201 |
--with-ijs \ |
202 |
--with-jbig2dec \ |
203 |
--with-libpaper \ |
204 |
--with-system-libtiff \ |
205 |
--without-luratech \ |
206 |
$(use_enable cups) \ |
207 |
$(use_enable dbus) \ |
208 |
$(use_enable gtk) \ |
209 |
$(use_with cups install-cups) \ |
210 |
$(use_with cups pdftoraster) \ |
211 |
$(use_with idn libidn) \ |
212 |
$(use_with jpeg2k jasper) \ |
213 |
$(use_with X x) |
214 |
|
215 |
if ! use bindist && use djvu ; then |
216 |
sed -i -e 's!$(DD)bbox.dev!& $(DD)djvumask.dev $(DD)djvusep.dev!g' Makefile |
217 |
fi |
218 |
|
219 |
cd "${S}/ijs" |
220 |
econf \ |
221 |
--enable-shared \ |
222 |
$(use_enable static-libs static) |
223 |
} |
224 |
|
225 |
src_compile() { |
226 |
emake -j1 so all || die "emake failed" |
227 |
|
228 |
cd "${S}/ijs" |
229 |
emake || die "ijs emake failed" |
230 |
} |
231 |
|
232 |
src_install() { |
233 |
# workaround: -j1 -> see bug #356303 |
234 |
emake -j1 DESTDIR="${D}" install-so install || die "emake install failed" |
235 |
|
236 |
# workaround: some printer drivers still require pstoraster, bug #383831 |
237 |
use cups && dosym /usr/libexec/cups/filter/gstoraster /usr/libexec/cups/filter/pstoraster |
238 |
# workaround: do the same for pstopxl as of gs 9.05 |
239 |
use cups && dosym /usr/libexec/cups/filter/gstopxl /usr/libexec/cups/filter/pstopxl |
240 |
|
241 |
if ! use bindist && use djvu ; then |
242 |
dobin gsdjvu || die "dobin gsdjvu install failed" |
243 |
fi |
244 |
|
245 |
# remove gsc in favor of gambit, bug #253064 |
246 |
rm -rf "${D}/usr/bin/gsc" |
247 |
|
248 |
rm -rf "${D}/usr/share/doc/${PF}/html/"{README,PUBLIC} |
249 |
dodoc doc/GS9_Color_Management.pdf || die "dodoc install failed" |
250 |
|
251 |
cd "${S}/ijs" |
252 |
emake DESTDIR="${D}" install || die "emake ijs install failed" |
253 |
|
254 |
# rename the original cidfmap to cidfmap.GS |
255 |
mv "${D}/usr/share/ghostscript/${PVM}/Resource/Init/cidfmap"{,.GS} || die |
256 |
|
257 |
# install our own cidfmap to handle CJK fonts |
258 |
insinto "/usr/share/ghostscript/${PVM}/Resource/Init" |
259 |
doins "${WORKDIR}/fontmaps/CIDFnmap" || die "doins CIDFnmap failed" |
260 |
doins "${WORKDIR}/fontmaps/cidfmap" || die "doins cidfmap failed" |
261 |
for X in ${LANGS} ; do |
262 |
if use linguas_${X} ; then |
263 |
doins "${WORKDIR}/fontmaps/cidfmap.${X}" || die "doins cidfmap.${X} failed" |
264 |
fi |
265 |
done |
266 |
|
267 |
# install the CMaps from poppler-data properly, bug 409361 |
268 |
dosym /usr/share/poppler/cMaps /usr/share/ghostscript/${PVM}/Resource/CMap |
269 |
|
270 |
use static-libs || find "${D}" -name '*.la' -delete |
271 |
} |