6 # http://dl.sourceforge.net/djvu/gsdjvu-1.3.tar.gz (or newer)
9 %bcond_without system_jbig2dec # build with included jbig2dec
10 %bcond_with svga # with svgalib display support (vgalib and lvga256 devices)
11 %bcond_without gtk # without gsx
13 Summary: PostScript & PDF interpreter and renderer
14 Summary(de.UTF-8): PostScript & PDF Interpreter und Renderer
15 Summary(fr.UTF-8): Interpréteur et visualisateur PostScript & PDF
16 Summary(ja.UTF-8): PostScript インタープリタ・レンダラー
17 Summary(pl.UTF-8): Bezpłatny interpreter i renderer PostScriptu i PDF
18 Summary(tr.UTF-8): PostScript & PDF yorumlayıcı ve gösterici
23 Group: Applications/Graphics
24 Source0: http://dl.sourceforge.net/ghostscript/%{name}-%{version}.tar.bz2
25 # Source0-md5: b13289cb2115f38f40c5e064f87e228a
26 Source1: http://www.mif.pg.gda.pl/homepages/ankry/man-PLD/%{name}-non-english-man-pages.tar.bz2
27 # Source1-md5: 9b5953aa0cc155f4364f20036b848585
28 Patch0: %{name}-missquotes.patch
29 Patch1: %{name}-setuid.patch
30 Patch2: %{name}-time_h.patch
31 Patch3: %{name}-am.patch
32 # no device for cdj850 in non-espgs ghostscript
33 # look for patch in old spec for GNU ghostscript
34 #Patch4: %{name}-gdevcd8-fixes.patch
35 #Patch5: %{name}-glib.patch
36 URL: http://www.ghostscript.com/
37 # https://bugzilla.redhat.com/show_bug.cgi?id=487742
38 # https://bugzilla.redhat.com/show_bug.cgi?id=487744
40 BuildRequires: security(CVE-2009-0583)
41 BuildRequires: security(CVE-2009-0584)
43 # Secunia Research 09/04/2009
45 # https://rhn.redhat.com/errata/RHSA-2009-0421.html
46 BuildRequires: security(CVE-2009-0196)
47 # http://bugs.ghostscript.com/show_bug.cgi?id=690211
48 BuildRequires: security(690211)
49 BuildRequires: autoconf
50 BuildRequires: automake
51 BuildRequires: docbook-style-dsssl
52 BuildRequires: glib2-devel
53 %{?with_system_jbig2dec:BuildRequires: jbig2dec-devel}
55 %{?with_gtk:BuildRequires: gtk+-devel}
56 BuildRequires: libpng-devel >= 1.0.8
57 BuildRequires: libstdc++-devel
58 BuildRequires: libtiff-devel
59 BuildRequires: libtool
60 BuildRequires: pkgconfig
61 # Required by 'gdevvglb' device.
62 %{?with_svga:BuildRequires: svgalib-devel}
63 # for documentation regeneration
65 BuildRequires: tetex-dvips
66 BuildRequires: xorg-lib-libXext-devel
67 BuildRequires: xorg-lib-libXt-devel
68 Obsoletes: ghostscript-afpl
69 Obsoletes: ghostscript-gpl
70 Obsoletes: ghostscript-esp
71 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
74 cos nGhostscript is a PostScript interpreter. It can render both
75 PostScript and PDF compliant files to devices which include an X
76 window, many printer formats (including support for color printers),
77 and popular graphics file formats.
79 %description -l de.UTF-8
80 Ghostscipt ist ein PostScript-Interpretierer. Er kann sowohl
81 PostScript als auch PDF-konforme Dateien an Geräte ausgeben, zu denen
82 ein X-Fenster, viele Druckerformate (einschließlich Support für
83 Farbdrucker) und gängige Grafikdateiformate zählen.
85 %description -l fr.UTF-8
86 Ghostscript est un interpréteur PostScript. Il peut rendre des
87 fichiers PostScript ou PDF sur des périphériques dont une fenêtre X,de
88 nombreux types d'imprimantes (dont un support pour imprimantes
89 couleur), et des formats de fichiers graphiques populaires.
91 %description -l ja.UTF-8
92 Ghostscript は PostScript インタープリタです。ポストスクリプトと PDF
93 をレンダリングし、X window や他のプリンタフォーマットで出力
94 します。このパッケージは日本語対応しています。
96 %description -l pl.UTF-8
97 Ghostcript jest interpreterem PostScriptu, języka używanego do opisu
98 formatu dokumentu. Ghostscript potrafi przetworzyć dokument w formacie
99 PostScript i PDF na szereg postaci wyjściowych: drukarki (włączając
100 kolorowe), okno X-Window i popularne formaty graficzne.
102 %description -l tr.UTF-8
103 GhostScript, PostScript ve PDF uyumlu dosyaları, X penceresinde
104 gösterebilir ve birçok yazıcının (renkli yazıcılar dahil) basabileceği
108 Summary: Ghostscript CUPS files
109 Summary(pl.UTF-8): Pliki Ghostscripta dla CUPS-a
110 Group: Applications/Graphics
111 Requires: %{name} = %{version}-%{release}
114 This package contains CUPS files provided by ghostscript.
116 %description cups -l pl.UTF-8
117 Ten pakiet zawiera pliki dla CUPS-a dostarczane przez ghostscript.
120 Summary: Ghostscript with GTK+ console
121 Summary(pl.UTF-8): Ghostscript z konsolą GTK+
122 Group: Applications/Graphics
123 Requires: %{name} = %{version}-%{release}
124 Obsoletes: ghostscript-afpl-gtk
125 Obsoletes: ghostscript-gpl-gtk
126 Obsoletes: ghostscript-esp-gtk
129 Ghostscript with GTK+ console.
131 %description gtk -l pl.UTF-8
132 Ghostscript z konsolą GTK+.
135 Summary: libgs header files
136 Summary(pl.UTF-8): Pliki nagłówkowe libgs
137 Group: Development/Libraries
138 Requires: %{name} = %{version}-%{release}
139 Obsoletes: ghostscript-afpl-devel
140 Obsoletes: ghostscript-esp-devel
143 Header files for libgs - ghostscript shared library.
145 %description devel -l pl.UTF-8
146 Pliki nagłówkowe libgs - współdzielonej biblioteki ghostscript.
149 Summary: IJS development files
150 Summary(pl.UTF-8): Pliki dla programistów IJS
151 Group: Development/Libraries
152 Requires: %{name} = %{version}-%{release}
153 Obsoletes: ghostscript-afpl-ijs-devel
154 Obsoletes: ghostscript-esp-ijs-devel
156 %description ijs-devel
157 IJS development files.
159 %description ijs-devel -l pl.UTF-8
160 Pliki do tworzenia programów z użyciem biblioteki IJS.
163 Summary: Static libijs library
164 Summary(pl.UTF-8): Statyczna biblioteka IJS
165 Group: Development/Libraries
166 Requires: %{name}-ijs-devel = %{version}-%{release}
167 Obsoletes: ghostscript-afpl-ijs-static
168 Obsoletes: ghostscript-esp-ijs-static
170 %description ijs-static
171 Static libijs library.
173 %description ijs-static -l pl.UTF-8
174 Statyczna wersja biblioteki IJS.
187 touch ijs/ijs-config.1
188 %if %{with system_jbig2dec}
189 if [ -d jbig2dec ]; then
200 CFLAGS="%{rpmcflags} -DA4 -fPIC"
203 --with-fontpath="%{_datadir}/fonts:%{_datadir}/fonts/Type1" \
208 --with-drivers=ALL%{?with_svga:,vgalib,lvga256} \
221 docdir=%{_docdir}/%{name}-%{version}
224 docdir=%{_docdir}/%{name}-%{version}
227 rm -rf $RPM_BUILD_ROOT
228 install -d $RPM_BUILD_ROOT{%{_datadir}/ghostscript/lib,%{_libdir},%{_includedir}/{ghostscript,ps}}
232 DESTDIR=$RPM_BUILD_ROOT \
233 docdir=%{_docdir}/%{name}-%{version}
235 %{__make} soinstall \
236 DESTDIR=$RPM_BUILD_ROOT \
237 docdir=%{_docdir}/%{name}-%{version}
239 %{__make} -C ijs install \
240 DESTDIR=$RPM_BUILD_ROOT
242 install lib/{pdfopt,pdfwrite}.ps Resource/Init/gs_frsd.ps $RPM_BUILD_ROOT%{_datadir}/%{name}/lib
245 install base/gdevdsp{,2}.h psi/{iapi,ierrors}.h $RPM_BUILD_ROOT%{_includedir}/ghostscript
247 rm -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/doc \
248 $RPM_BUILD_ROOT%{_bindir}/*.sh \
249 $RPM_BUILD_ROOT%{_mandir}/man1/{ps2pdf1{2,3},gsbj,gsdj,gsdj500,gslj,eps2eps}.1 \
250 $RPM_BUILD_ROOT%{_mandir}/de/man1/{ps2pdf1{2,3},eps2eps}.1
252 echo ".so gs.1" > $RPM_BUILD_ROOT%{_mandir}/man1/ghostscript.1
253 echo ".so ps2pdf.1" > $RPM_BUILD_ROOT%{_mandir}/man1/ps2pdf12.1
254 echo ".so ps2pdf.1" > $RPM_BUILD_ROOT%{_mandir}/man1/ps2pdf13.1
255 echo ".so ps2ps.1" > $RPM_BUILD_ROOT%{_mandir}/man1/eps2eps.1
256 echo ".so gslp.1" > $RPM_BUILD_ROOT%{_mandir}/man1/gsbj.1
257 echo ".so gslp.1" > $RPM_BUILD_ROOT%{_mandir}/man1/gsdj.1
258 echo ".so gslp.1" > $RPM_BUILD_ROOT%{_mandir}/man1/gsdj500.1
259 echo ".so gslp.1" > $RPM_BUILD_ROOT%{_mandir}/man1/gslj.1
261 echo ".so ps2ps.1" > $RPM_BUILD_ROOT%{_mandir}/de/man1/eps2eps.1
262 echo ".so ps2pdf.1" > $RPM_BUILD_ROOT%{_mandir}/de/man1/ps2pdf12.1
263 echo ".so ps2pdf.1" > $RPM_BUILD_ROOT%{_mandir}/de/man1/ps2pdf13.1
266 bzip2 -dc %{SOURCE1} | tar xf - -C $RPM_BUILD_ROOT%{_mandir}
268 #mv -f $RPM_BUILD_ROOT%{_bindir}/{gsc,gs}
269 ln -sf gs $RPM_BUILD_ROOT%{_bindir}/gsc
270 ln -sf gs $RPM_BUILD_ROOT%{_bindir}/ghostscript
273 rm -rf $RPM_BUILD_ROOT
275 %post -p /sbin/ldconfig
276 %postun -p /sbin/ldconfig
279 %defattr(644,root,root,755)
280 %doc %{_docdir}/%{name}-%{version}
281 %attr(755,root,root) %{_bindir}/[bdeflpsux]*
282 %attr(755,root,root) %{_bindir}/ghostscript
283 %attr(755,root,root) %{_bindir}/gs
284 %attr(755,root,root) %{_bindir}/wftopfa
285 %attr(755,root,root) %{_bindir}/gs[!x]*
286 %attr(755,root,root) %{_bindir}/ijs_*_example
287 %attr(755,root,root) %{_libdir}/libgs.so.*.*
288 %attr(755,root,root) %{_libdir}/libijs-*.so
289 %dir %{_libdir}/%{name}
290 %dir %{_libdir}/%{name}/*.*
291 %attr(755,root,root) %{_libdir}/%{name}/*.*/*.so
292 %dir %{_datadir}/%{name}
293 %dir %{_datadir}/%{name}/lib
294 %{_datadir}/%{name}/lib/*.*
295 %dir %{_datadir}/%{name}/%{version}
296 %dir %{_datadir}/%{name}/%{version}/lib
297 # "*.*" will not match "Fontmap". It is OK.
298 %{_datadir}/%{name}/%{version}/lib/*.*
299 %{_datadir}/%{name}/%{version}/lib/pphs
300 %{_datadir}/%{name}/%{version}/Resource
301 %{_datadir}/%{name}/%{version}/examples
303 %lang(cs) %{_mandir}/cs/man*/*
304 %lang(de) %{_mandir}/de/man*/*
305 %lang(es) %{_mandir}/es/man*/*
306 %lang(fr) %{_mandir}/fr/man*/*
307 %lang(pl) %{_mandir}/pl/man*/*
310 %defattr(644,root,root,755)
317 %defattr(644,root,root,755)
318 %attr(755,root,root) %{_bindir}/gsx
322 %defattr(644,root,root,755)
323 %attr(755,root,root) %{_libdir}/libgs.so
324 %{_includedir}/ghostscript
328 %defattr(644,root,root,755)
329 %attr(755,root,root) %{_bindir}/ijs-config
330 %attr(755,root,root) %{_libdir}/libijs.so
333 %{_pkgconfigdir}/*.pc
336 %defattr(644,root,root,755)