source: pst/printing/gs.xml@ 8070bb0c

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 7.10 7.4 7.5 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts krejzi/svn lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition systemd-11177 systemd-13485 trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since 8070bb0c was 8070bb0c, checked in by Randy McMurchy <randy@…>, 13 years ago

Added an optional dependency for the Ghostscript package

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@8783 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 14.4 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!-- <!ENTITY gs-download-http "&sourceforge-repo;/ghostscript/ghostscript-&gs-version;.tar.bz2"> -->
8 <!ENTITY gs-download-http "http://ghostscript.com/releases/ghostscript-&gs-version;.tar.gz">
9 <!-- no response 2010-12-18
10 <!ENTITY gs-download-ftp "ftp://mirror.cs.wisc.edu/pub/mirrors/ghost/GPL/gs900/ghostscript-&gs-version;.tar.gz"> -->
11 <!ENTITY gs-download-ftp " ">
12 <!ENTITY gs-md5sum "177c33b796ed28d3d568e230a6dbdba5">
13 <!ENTITY gs-size "22.3 MB">
14 <!ENTITY gs-buildsize "170 MB (includes installing libgs.so and both font tarballs)">
15 <!ENTITY gs-time "2.7 SBU (includes building and installing libgs.so)">
16
17 <!-- <!ENTITY gs-standard-fonts-download "ftp://ftp.imagemagick.org/pub/ImageMagick/delegates/ghostscript-fonts-std-8.11.tar.gz"> -->
18 <!ENTITY gs-standard-fonts-download "&sourceforge-repo;/gs-fonts/ghostscript-fonts-std-8.11.tar.gz">
19 <!ENTITY gs-standard-fonts-md5sum "6865682b095f8c4500c54b285ff05ef6">
20 <!ENTITY gs-standard-fonts-size "3.7 MB">
21
22 <!ENTITY gs-other-fonts-download "&sourceforge-repo;/gs-fonts/gnu-gs-fonts-other-6.0.tar.gz">
23 <!ENTITY gs-other-fonts-md5sum "33457d3f37de7ef03d2eea05a9e6aa4f">
24 <!ENTITY gs-other-fonts-size "796 KB">
25]>
26
27<sect1 id="gs" xreflabel="GPL Ghostscript-&gs-version;">
28 <?dbhtml filename="gs.html"?>
29
30 <sect1info>
31 <othername>$LastChangedBy$</othername>
32 <date>$Date$</date>
33 </sect1info>
34
35 <title>GPL Ghostscript-&gs-version;</title>
36
37 <indexterm zone="gs">
38 <primary sortas="a-GPL-Ghostscript">GPL Ghostscript</primary>
39 </indexterm>
40
41 <sect2 role="package">
42 <title>Introduction to Ghostscript</title>
43
44 <para><application>Ghostscript</application> is a versatile processor
45 for PostScript data with the ability to render PostScript to different
46 targets.</para>
47
48 &lfs67_checked;
49
50 <bridgehead renderas="sect3">Package Information</bridgehead>
51 <itemizedlist spacing="compact">
52 <listitem>
53 <para>Download (HTTP): <ulink url="&gs-download-http;"/></para>
54 </listitem>
55 <listitem>
56 <para>Download (FTP): <ulink url="&gs-download-ftp;"/></para>
57 </listitem>
58 <listitem>
59 <para>Download MD5 sum: &gs-md5sum;</para>
60 </listitem>
61 <listitem>
62 <para>Download size: &gs-size;</para>
63 </listitem>
64 <listitem>
65 <para>Estimated disk space required: &gs-buildsize;</para>
66 </listitem>
67 <listitem>
68 <para>Estimated build time: &gs-time;</para>
69 </listitem>
70 </itemizedlist>
71
72 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
73
74 <itemizedlist spacing='compact'>
75 <title>Standard Fonts</title>
76 <listitem>
77 <para>Download (FTP): <ulink url="&gs-standard-fonts-download;"/></para>
78 </listitem>
79 <listitem>
80 <para>Download MD5 sum: &gs-standard-fonts-md5sum;</para>
81 </listitem>
82 <listitem>
83 <para>Download size: &gs-standard-fonts-size;</para>
84 </listitem>
85 </itemizedlist>
86
87 <itemizedlist spacing='compact'>
88 <title>Other Fonts</title>
89 <listitem>
90 <para>Download (HTTP): <ulink url="&gs-other-fonts-download;"/></para>
91 </listitem>
92 <listitem>
93 <para>Download MD5 sum: &gs-other-fonts-md5sum;</para>
94 </listitem>
95 <listitem>
96 <para>Download size: &gs-other-fonts-size;</para>
97 </listitem>
98 </itemizedlist>
99
100 <itemizedlist spacing="compact">
101 <title>Patches</title>
102 <listitem>
103 <para>Required patch: <ulink
104 url="&patch-root;/ghostscript-&gs-version;-security_fixes-1.patch"/>
105 </para>
106 </listitem>
107 <listitem>
108 <para>Recommended patch (unless you build without JPEG2000 support) : <ulink
109 url="&patch-root;/ghostscript-&gs-version;-system_jasper-1.patch"/>
110 </para>
111 </listitem>
112 </itemizedlist>
113
114 <bridgehead renderas="sect3">Ghostscript Dependencies</bridgehead>
115
116 <bridgehead renderas="sect4">Recommended</bridgehead>
117 <para role="optional"><xref linkend="expat"/>,
118 <xref linkend="freetype2"/>,
119 <xref linkend="jasper"/>
120 <xref linkend="libjpeg"/>,
121 <xref linkend="libpng"/>,
122 <xref linkend="libtiff"/>, and
123 <xref linkend="lcms"/></para>
124
125 <bridgehead renderas="sect4">Optional</bridgehead>
126 <para role="optional">
127 <xref linkend="cairo"/>,
128 <xref linkend="fontconfig"/>,
129 <xref linkend="gtk2"/>,
130 <xref linkend="cups"/>,
131 <xref linkend="libidn"/>,
132 <xref linkend="x-window-system"/>, and
133 <!-- the link for ijs source ultimately takes users back to the ghostscript site
134 <ulink url="http://www.linuxprinting.org/ijs/">IJS</ulink>, and -->
135 <ulink url="http://packages.debian.org/unstable/source/libpaper">libpaper</ulink></para>
136
137 <para condition="html" role="usernotes">User Notes:
138 <ulink url="&blfs-wiki;/gs"/></para>
139
140 </sect2>
141
142 <sect2 role="installation">
143 <title>Installation of Ghostscript</title>
144
145 <para>Install <application>GPL Ghostscript</application> by running the
146 following commands:</para>
147
148 <note>
149 <para>The <application>Ghostscript</application> build system is not
150 user-friendly. In order to use system copies of various graphics
151 libraries, you must do it using unconventional methods.</para>
152 </note>
153
154 <para>Begin by patching some vulnerabilities:</para>
155
156<screen><userinput>patch -Np1 -i ../ghostscript-&gs-version;-security_fixes-1.patch
157</userinput></screen>
158
159 <para><application>GPL Ghostscript</application> includes (old) copies of
160 several libraries. Some of these seem to have been patched to fix known
161 vulnerabilities, but others of these copies are less-well maintained.
162 To ensure that any future fixes are applied throughout the whole system,
163 it is recommended that you build the released versions of these libraries
164 and then configure <application>GPL Ghostscript</application> to link to
165 them. This configuration has several steps.</para>
166
167 <para>Unless you intend to build <application>GPL Ghostscript</application>
168 without support for <literal>JPEG2000</literal> files, apply a patch to
169 allow it to build against a current system-installed version of
170 <application>JasPer</application>:</para>
171
172<screen><userinput>patch -Np1 -i ../ghostscript-&gs-version;-system_jasper-1.patch
173</userinput></screen>
174
175 <para>Remove the local copies of <application>expat</application>,
176 <application>JasPer</application>, <application>lcms</application>,
177 <application>libjpeg</application>, <application>libpng</application>,
178 <application>libtiff</application>, and <application>zlib</application>:
179 </para>
180
181<screen><userinput>rm -rf expat jasper lcms jpeg libpng tiff zlib
182</userinput></screen>
183
184 <para>Run the configure command:</para>
185
186<screen><userinput>./configure --prefix=/usr --enable-dynamic --with-drivers=ALL,x11 --with-system-libtiff --disable-compile-inits</userinput></screen>
187
188 <para>To ensure the build is able to use the system versions of
189 <application>expat</application>, <application>freetype</application>, and
190 <application>lcms</application> it is necessary to make some changes and an
191 addition to the <literal>Makefile</literal> before building the package:</para>
192
193<screen><userinput>sed -i -e 's|SHARE_LCMS=0|SHARE_LCMS=1|' \
194 -e 's|LCMSSRCDIR=lcms|LCMSSRCDIR=/usr|' \
195 -e 's|=imdi|&amp;\n\n# Use system expat library\n\nSHARE_EXPAT=1|' \
196 -e 's|SHARE_FT=0|SHARE_FT=1|' Makefile &amp;&amp;
197make</userinput></screen>
198
199 <para>This package does not come with a test suite. However, you may test
200 the operation of the newly built <command>gs</command> program by
201 issuing the following command (issue from an X Windows terminal):</para>
202
203 <screen><userinput>bin/gs -Ilib -dBATCH examples/tiger.eps</userinput></screen>
204
205 <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
206
207<!-- for 9.00 docdir is only referenced by GS_DOCDIR which is itself not referenced
208 so the docs still go into /usr/share/ghostscript/9.00/
209<screen role="root"><userinput>make install docdir=/usr/share/doc/ghostscript-&gs-version; &amp;&amp;-->
210<screen role="root"><userinput>make install &amp;&amp;
211for INSTFILE in `ls doc`
212do
213 <!--if [ ! -f /usr/share/doc/ghostscript-&gs-version;/$INSTFILE ]; then -->
214 if [ ! -f /usr/share/ghostscript/&gs-version;/doc/$INSTFILE ]; then
215 install -v -m644 doc/$INSTFILE \
216 /usr/share/ghostscript/&gs-version;/doc
217 <!--/usr/share/doc/ghostscript-&gs-version;-->
218 fi
219done &amp;&amp;
220
221<!--install -v -m755 -d /usr/share/doc/ghostscript-&gs-version;/figures &amp;&amp;-->
222install -v -m755 -d /usr/share/ghostscript/&gs-version;/doc/figures &amp;&amp;
223install -v -m644 doc/figures/* \
224 /usr/share/ghostscript/&gs-version;/doc/figures &amp;&amp;
225 <!--/usr/share/doc/ghostscript-&gs-version;/figures-->
226ln -sv ../ghostscript/&gs-version;/doc /usr/share/doc/ghostscript-&gs-version;
227</userinput></screen>
228
229 <para>To install the shared library
230 <filename class='libraryfile'>libgs.so</filename>, run the
231 following additional command as an unprivileged user:</para>
232
233<screen><userinput>make so</userinput></screen>
234
235 <para>And again as the <systemitem class="username">root</systemitem>
236 user:</para>
237
238<screen role="root"><userinput>make soinstall docdir=/usr/share/doc/ghostscript-&gs-version; &amp;&amp;
239install -v -m644 base/*.h /usr/include/ghostscript &amp;&amp;
240ln -v -s ghostscript /usr/include/ps</userinput></screen>
241
242 <note>
243 <para>The shared library depends on <xref linkend="gtk2"/>. It is
244 only used in external programs like <xref linkend="gsview"/> and
245 <xref linkend="imagemagick"/>.</para>
246 </note>
247
248 <para>To finish the installation, unpack all fonts you've downloaded to
249 <filename class="directory">/usr/share/ghostscript</filename> and ensure
250 the ownerships of the files are
251 <systemitem class="username">root</systemitem>:<systemitem
252 class="groupname">root</systemitem>. Substitute
253 <replaceable>&lt;font-tarball&gt;</replaceable> appropriately in
254 the command below for the fonts you wish to install:</para>
255
256<screen role="root"><userinput>tar -xvf ../<replaceable>&lt;font-tarball&gt;</replaceable> \
257 -C /usr/share/ghostscript --no-same-owner</userinput></screen>
258
259 </sect2>
260
261 <sect2 role="commands">
262 <title>Command Explanations</title>
263
264 <para><command>--with-drivers=ALL,x11</command>: This parameter adds the
265 <literal>x11</literal> output device to the default (<literal>ALL</literal>)
266 selection so that the test to render the tiger will work on 32-bit systems
267 (this does no harm on the <literal>x86_64</literal> architecture, although
268 it is not required there).</para>
269 <para><command>--disable-compile-inits</command>: This parameter is intended
270 to avoid compiling initialization files into the executables. It is used here
271 to simplify building agaisnt the system version of
272 <application>zlib</application>.</para>
273 <para><option>--without-jasper</option>: If you know you do not wish to print
274 any <literal>JPEG2000</literal> files, this switch (and removing the
275 <filename class="directory">jasper/</filename> source) will achieve this.</para>
276 <para><option>--without-jbig2dec</option>: The <literal>JBIG2</literal>
277 decompression code (used for some faxes) can be disabled by using this switch
278 and removing the <filename class="directory">jbig2dec/</filename> source.</para>
279 <para><command>install ...</command>: Some packages
280 (<application>ImageMagick</application> is one) need the
281 <application>Ghostscript</application> interface headers in place to link
282 to the shared library. These commands install the headers.</para>
283
284 <para><command>ln -sv ... /usr/share/doc/ghostscript-&gs-version;</command>: This puts
285 the documentation where it is expected to be found.</para>
286
287 <para><command>ln -v -s ghostscript /usr/include/ps</command>: Some
288 packages expect to find the interface headers in an alternate
289 location.</para>
290
291 </sect2>
292
293 <sect2 role="content">
294 <title>Contents</title>
295 <segmentedlist>
296 <segtitle>Installed Programs</segtitle>
297 <segtitle>Installed Library</segtitle>
298 <segtitle>Installed Directories</segtitle>
299
300 <seglistitem>
301 <seg>bdftops, dumphint, dvipdf, eps2eps, fixmswrd.pl, font2c, gs, gsbj,
302 gsc (from soinstall), gsdj, gsdj500, gslj, gslp, gsnd, gsx (from soinstall),
303 lprsetup.sh, pdf2dsc, pdf2ps, pdfopt,
304 pf2afm, pfbtopfa, printafm, ps2ascii, ps2epsi, ps2pdf, ps2pdf12,
305 ps2pdf13, ps2pdf14, ps2pdfwr, ps2ps, ps2ps2, pv.sh, unix-lpr.sh, and
306 wftopfa</seg>
307 <seg>libgs.so </seg>
308 <seg>/usr/include/ghostscript, /usr/lib/ghostscript, /usr/share/ghostscript,
309 <!--and /usr/share/doc/ghostscript</seg>-->
310 and /usr/share/doc/ghostscript-&gs-version;</seg>
311 </seglistitem>
312 </segmentedlist>
313
314 <variablelist>
315 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
316 <?dbfo list-presentation="list"?>
317 <?dbhtml list-presentation="table"?>
318
319 <varlistentry id="gplgs-prog">
320 <term><command>gs</command></term>
321 <listitem>
322 <para>is an interpreter for Adobe Systems' PostScript(tm) and Portable Document Format
323 (PDF).</para>
324 <indexterm zone="gs gplgs-prog">
325 <primary sortas="b-gs">gs</primary>
326 </indexterm>
327 </listitem>
328 </varlistentry>
329
330 <varlistentry id="libgs.so">
331 <term><filename class="libraryfile">libgs.so</filename></term>
332 <listitem>
333 <para>provides <application>Ghostscript</application> functionality
334 to other programs, such as <application>GSView</application>,
335 <application>ImageMagick</application>, and
336 <application>libspectre</application>.</para>
337 <indexterm zone="gs libgs.so">
338 <primary sortas="c-libgs.so">libgs.so</primary>
339 </indexterm>
340 </listitem>
341 </varlistentry>
342
343 </variablelist>
344
345 <para><application>GPL Ghostscript</application> provides many different
346 scripts used to convert PostScript, PDF, and other formats. Please refer to
347 the HTML documentation or the man pages for information about the
348 capabilities provided.</para>
349
350 </sect2>
351
352</sect1>
Note: See TracBrowser for help on using the repository browser.