source: pst/ps/fop.xml@ 6732c094

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 6.3 6.3-rc1 6.3-rc2 6.3-rc3 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 6732c094 was 6732c094, checked in by Randy McMurchy <randy@…>, 17 years ago

Updated all the XML files (and the one stylesheet) to use the 4.5 version of DocBook XML DTD

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

  • Property mode set to 100644
File size: 16.5 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 fop-download-http "http://apache.mirrors.pair.com/xmlgraphics/fop/fop-&fop-version;-src.tar.gz">
8 <!ENTITY fop-download-ftp "ftp://apache.mirrors.pair.com/xmlgraphics/fop/fop-&fop-version;-src.tar.gz">
9 <!ENTITY fop-md5sum "184c578a6269a8287ed150e0fc12868d">
10 <!ENTITY fop-size "11.7 MB">
11 <!ENTITY fop-buildsize "216 MB">
12 <!ENTITY fop-time "0.9 SBU">
13
14 <!ENTITY jai-download "http://javashoplm.sun.com/ECom/docs/Welcome.jsp?StoreId=22&amp;PartDetailId=jai-1_1_2_01-oth-JPR&amp;SiteId=JSC&amp;TransactionId=noreg">
15 <!ENTITY jai-md5sum "f2be3619a8d002eff3874355e96327eb">
16 <!ENTITY jai-size "2.6 MB">
17
18 <!ENTITY offo-download "http://downloads.sourceforge.net/offo/offo-hyphenation.zip">
19 <!ENTITY offo-md5sum "0b8c1657ef70285ad7fd514061b08c3e">
20 <!ENTITY offo-size "359 KB">
21]>
22
23<sect1 id="fop" xreflabel="FOP-&fop-version;">
24 <?dbhtml filename="fop.html"?>
25
26 <sect1info>
27 <othername>$LastChangedBy$</othername>
28 <date>$Date$</date>
29 </sect1info>
30
31 <title>FOP-&fop-version;</title>
32
33 <indexterm zone="fop">
34 <primary sortas="a-FOP">FOP</primary>
35 </indexterm>
36
37 <sect2 role="package">
38 <title>Introduction to FOP</title>
39
40 <para>The <application>FOP</application> (Formatting Objects Processor)
41 package contains a print formatter driven by XSL formatting objects
42 (XSL-FO). It is a <application>Java</application> application that reads
43 a formatting object tree and renders the resulting pages to a specified
44 output. Output formats currently supported include PDF, PCL, PostScript,
45 SVG, XML (area tree representation), print, AWT, MIF and ASCII text. The
46 primary output target is PDF.</para>
47
48 <bridgehead renderas="sect3">Package Information</bridgehead>
49 <itemizedlist spacing="compact">
50 <listitem>
51 <para>Download (HTTP): <ulink url="&fop-download-http;"/></para>
52 </listitem>
53 <listitem>
54 <para>Download (FTP): <ulink url="&fop-download-ftp;"/></para>
55 </listitem>
56 <listitem>
57 <para>Download MD5 sum: &fop-md5sum;</para>
58 </listitem>
59 <listitem>
60 <para>Download size: &fop-size;</para>
61 </listitem>
62 <listitem>
63 <para>Estimated disk space required: &fop-buildsize;</para>
64 </listitem>
65 <listitem>
66 <para>Estimated build time: &fop-time;</para>
67 </listitem>
68 </itemizedlist>
69
70 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
71
72 <itemizedlist spacing="compact">
73 <title>Required packages</title>
74 <listitem>
75 <para>Objects for Formatting Objects (OFFO) hyphenation patterns:
76 <simplelist>
77 <member><ulink url="&offo-download;"/></member>
78 <member>&offo-md5sum;</member>
79 <member>&offo-size;</member>
80 </simplelist>
81 </para>
82 </listitem>
83 <listitem>
84 <para>Java Advanced Imaging (JAI) API components:
85 <simplelist>
86 <member>
87 <ulink url="&jai-download;">
88 http://javashoplm.sun.com/ECom/docs/Welcome.jsp?StoreId=22&amp;</ulink>
89 <ulink url="&jai-download;">
90 PartDetailId=jai-1_1_2_01-oth-JPR&amp;SiteId=JSC&amp;TransactionId=noreg</ulink>
91 </member>
92 <member>&jai-md5sum;</member>
93 <member>&jai-size;</member>
94 <member>Choose the <quote>Linux JDK Install</quote> file after
95 accepting the license agreement.</member>
96 </simplelist>
97 </para>
98 </listitem>
99 </itemizedlist>
100
101 <!-- <itemizedlist spacing='compact'>
102 <title>Required patch</title>
103 <listitem>
104 <para><ulink
105 url="&patch-root;/fop-&fop-version;-jdk_1.5.0-1.patch"/></para>
106 </listitem>
107 </itemizedlist> -->
108
109 <bridgehead renderas="sect3">FOP Dependencies</bridgehead>
110
111 <bridgehead renderas="sect4">Required</bridgehead>
112 <para role="required"><xref linkend="apache-ant"/></para>
113
114 <bridgehead renderas="sect4">Optional</bridgehead>
115 <para role="optional"><ulink url="http://java.sun.com/products/jimi/">JIMI SDK</ulink>,
116 <ulink url="http://xmlunit.sourceforge.net/">XMLUnit</ulink>, and
117 <ulink url="http://forrest.apache.org/">Forrest</ulink> (only used to rebuild
118 the documentation)</para>
119
120 <para condition="html" role="usernotes">User Notes:
121 <ulink url="&blfs-wiki;/fop"/></para>
122
123 </sect2>
124
125 <sect2 role="installation">
126 <title>Installation of FOP</title>
127
128 <para>Ensure <envar>$JAVA_HOME</envar> is set correctly before beginning
129 the build. To build the <application>JIMI SDK</application> and/or
130 <application>XMLUnit</application> extension classes, ensure the
131 corresponding <filename class='extension'>.jar</filename> files are
132 identified in the <envar>CLASSPATH</envar> environment variable.</para>
133
134 <!-- <para>Some versions of tar will display a message similar to
135 <quote><computeroutput>tar: A lone zero block at 33476</computeroutput></quote>
136 when unpacking the source tarball. You may safely ignore this message.</para> -->
137
138 <sect3>
139 <title>Installing OFFO Hyphenation Patterns</title>
140
141 <para>Before beginning the build, unpack the
142 <application>FOP</application> source tarball and the hyphenation zipfile
143 from the same directory, then change directories into the root of the
144 <application>FOP</application> source tree. The XML Hyphenation patterns
145 will be copied into the <application>FOP</application> source tree by
146 running the following commands:</para>
147
148<screen><userinput>cp ../offo-hyphenation/hyph/* hyph &amp;&amp;
149rm -rf ../offo-hyphenation</userinput></screen>
150
151 </sect3>
152
153 <sect3>
154 <title>Installing JAI</title>
155
156 <tip>
157 <para>The <command>$FOP_BUILD_DIR/JAI.bin</command>
158 command below installs the JAI components in the JDK tree. You will be
159 required to view, and then accept (by entering a <keycap>y</keycap>
160 keypress), a license agreement before the installation will continue.
161 If you are scripting (automating) the build, you'll need to account for
162 this. There is information about automating build commands in the
163 <xref linkend="automating-builds"/> section of Chapter 2. Towards the
164 end of this section, specific information for automating this type of
165 installation is discussed.</para>
166 </tip>
167
168 <para>Install the JAI components by running the following commands as
169 the <systemitem class="username">root</systemitem> user while in the
170 root of the <application>FOP</application> source tree:</para>
171
172<screen role="root"><userinput>install -m755 ../jai-1_1_2_01-lib-linux-i586-jdk.bin JAI.bin &amp;&amp;
173sed -i 's/tail +122/tail -n +122/' JAI.bin &amp;&amp;
174
175FOP_BUILD_DIR=$(pwd) &amp;&amp;
176cd $JAVA_HOME &amp;&amp;
177
178$FOP_BUILD_DIR/JAI.bin &amp;&amp;
179
180cd $FOP_BUILD_DIR &amp;&amp;
181rm JAI.bin</userinput></screen>
182
183 </sect3>
184
185 <sect3>
186 <title>Installing FOP Components</title>
187
188 <para>Install <application>FOP</application> by running the
189 following commands:</para>
190
191<screen><userinput>ant &amp;&amp;
192ant javadocs</userinput></screen>
193
194 <para>The unit regression tests were performed in the build step
195 above.</para>
196
197 <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
198
199<screen role="root"><userinput>install -v -d -m755 /opt/fop-&fop-version; &amp;&amp;
200cp -v -R * /opt/fop-&fop-version; &amp;&amp;
201ln -v -sf fop-&fop-version; /opt/fop</userinput></screen>
202
203 </sect3>
204
205 <!-- <sect3>
206 <title>Installing the Batik JAR</title>
207
208 <para>You'll need to install one additional <application>Java</application>
209 class library to process SVG objects. This library is part of the
210 <ulink url="http://xml.apache.org/batik/">Batik</ulink> package, but is
211 also included with the <application>FOP</application> package. If you
212 have <application>Batik</application> installed, ensure the
213 <filename>batik.jar</filename> library is included in your
214 <envar>$CLASSPATH</envar> environment variable. Alternatively, create a
215 symbolic link from <filename>/opt/fop-&fop-version;/lib/batik.jar</filename>
216 pointing to the full path of the installed <filename>batik.jar</filename>
217 file so that the <command>fop.sh</command> script will automatically pick it
218 up.</para>
219
220 <para>If you don't have the <application>Batik</application> package
221 installed, run the following commands as the <systemitem
222 class="username">root</systemitem> user:</para>
223
224<screen role="root"><userinput>install -v -m644 lib/batik.jar /opt/fop-&fop-version;/lib &amp;&amp;
225install -v -m644 lib/batik.LICENSE.txt \
226 /opt/fop-&fop-version;/docs/lib</userinput></screen>
227
228 </sect3>
229
230 <sect3>
231 <title>Installing the Xalan-Java components</title>
232
233 <para>The components of <application>FOP</application> required to
234 process FO files created by an XSL transformation engine (also known
235 as an XSLT processor) is now complete. An XSL transformation engine
236 (<command>xsltproc</command>) is included with the
237 <xref linkend="libxslt"/> package in BLFS. The
238 <application>FOP</application> package includes components of
239 <ulink url="http://xml.apache.org/xalan-j/">Xalan-Java</ulink> to
240 accomplish XSL transformations. If you have the
241 <application>Xalan-Java</application> package installed, skip to
242 the next section.</para>
243
244 <para>If you wish to install the <application>Xalan-Java</application>
245 components provided by the <application>FOP</application>
246 package, run the following commands as the <systemitem
247 class="username">root</systemitem> user:</para>
248
249<screen role="root"><userinput>sed -i "s/build/lib/" xalan.sh &amp;&amp;
250install -v -m755 xalan.sh /opt/fop-&fop-version;/bin &amp;&amp;
251install -v -m644 lib/xml-apis.jar \
252 lib/xercesImpl-2.2.1.jar \
253 lib/xalan-2.4.1.jar \
254 /opt/fop-&fop-version;/lib &amp;&amp;
255install -v -m644 lib/{xml-apis,xerces,xalan}.LICENSE.txt \
256 lib/xml-apis.README.txt \
257 /opt/fop-&fop-version;/docs/lib</userinput></screen>
258
259 </sect3>
260
261 <sect3>
262 <title>Installing the Jimi SDK JAR</title>
263
264 <para>If you installed the Java Image I/O class library
265 (<application>Jimi SDK</application>) into the
266 <application>FOP</application> source tree
267 <filename class='directory'>lib</filename> directory before building
268 <application>FOP</application> (this will enable Jimi
269 support), ensure you also install this JAR file into
270 <filename class='directory'>/opt/fop-&fop-version;/lib</filename>.</para>
271
272 </sect3> -->
273
274 </sect2>
275
276 <sect2 role="commands">
277 <title>Command Explanations</title>
278
279 <para><command>sed -i 's/tail +122/tail -n +122/' ...</command>:
280 The <application>JAI</application> binary file has a <command>tail</command>
281 command imbedded in the file which uses obsolete syntax and causes the
282 file to unpack incorrectly. This command fixes the obsolete
283 syntax.</para>
284
285 <para><command>$FOP_BUILD_DIR/JAI.bin</command>: This
286 command installs the <application>JAI</application> components
287 into the <application>JDK</application> file structure.
288 <envar>$FOP_BUILD_DIR</envar> is used as a reference point to the source
289 executable and as a method to return back to the
290 <application>FOP</application> source tree.</para>
291
292 <!-- <para><command>sed -i "s/build/lib/" ...</command>: These commands modify
293 the installed shell scripts so that the location of the installed
294 <filename>fop.jar</filename> file is correctly identified.</para> -->
295
296 <!-- <para><command>install -v ...; cp -v ...</command>: There is no installation
297 script provided by the <application>FOP</application>
298 package. These commands install the package.</para> -->
299
300 <para><command>ant</command>: This reads the <filename>build.xml</filename>
301 file and performs the default <option>all</option> target which builds the
302 package and runs the unit regression tests.</para>
303
304 <para><command>ant javadocs</command>: This builds the Java API
305 documentation. Omit this step if desired.</para>
306
307 <para><command>ln -v -sf fop-&fop-version; /opt/fop</command>: This is
308 optional and creates a convenience symlink so that <envar>$FOP_HOME</envar>
309 doesn't have to be changed each time there's a package version change.</para>
310
311 </sect2>
312
313 <sect2 role="configuration">
314 <title>Configuring FOP</title>
315
316 <sect3 id="fop-config">
317 <title>Config Files</title>
318
319 <para><filename>~/.foprc</filename></para>
320
321 <indexterm zone="fop fop-config">
322 <primary sortas="e-AA.foprc">~/.foprc</primary>
323 </indexterm>
324
325 </sect3>
326
327 <sect3>
328 <title>Configuration Information</title>
329
330 <para>Using <application>FOP</application> to process some large FO's
331 (including the FO derived from the BLFS XML sources), can lead to memory
332 errors. Unless you add a parameter to the <command>java</command> command
333 used in the <command>fop</command> script you may receive messages
334 similar to the one shown below:</para>
335
336 <para><computeroutput>Exception in thread "main" java.lang.OutOfMemoryError:
337 Java heap space</computeroutput></para>
338
339 <para>To avoid errors like this, you need to pass an extra parameter to
340 the <command>java</command> command used in the <command>fop</command>
341 script. This can be accomplished by creating a
342 <filename>~/.foprc</filename> (which is sourced by the
343 <command>fop</command> script) and adding the parameter to the
344 <envar>FOP_OPTS</envar> environment variable.</para>
345
346 <para>The <command>fop</command> script looks for a
347 <envar>FOP_HOME</envar> environment variable to locate the
348 <application>FOP</application> class libraries. You can create this
349 variable using the <filename>~/.foprc</filename> file as well. Create
350 a <filename>~/.foprc</filename> file using the following commands:</para>
351
352<screen><userinput>cat &gt; ~/.foprc &lt;&lt; "EOF"
353<literal>FOP_OPTS="-Xmx<replaceable>&lt;RAM_Installed&gt;</replaceable>m"
354FOP_HOME="/opt/fop"</literal>
355
356EOF</userinput></screen>
357
358 <para>Replace <replaceable>&lt;RAM_Installed&gt;</replaceable> with a
359 number representing the amount of RAM installed in your computer (in
360 megabytes). An example would be
361 <userinput>FOP_OPTS="-Xmx768m"</userinput>. For more information about
362 memory issues running <application>FOP</application>, see
363 <ulink url="http://xml.apache.org/fop/running.html#memory"/>.</para>
364
365 <para>To include the <command>fop</command> script in your path,
366 update your personal or system-wide profile with the following:</para>
367
368<screen><literal>PATH=$PATH:/opt/fop</literal></screen>
369
370 </sect3>
371
372 </sect2>
373
374 <sect2 role="content">
375 <title>Contents</title>
376
377 <segmentedlist>
378 <segtitle>Installed Programs</segtitle>
379 <segtitle>Installed Libraries</segtitle>
380 <segtitle>Installed Directory</segtitle>
381
382 <seglistitem>
383 <seg>fop</seg>
384 <seg>fop.jar and numerous support library classes located in
385 <filename class='directory'>/opt/fop/{build,lib}</filename>; JAI
386 components include libmlib_jai.so, jai_codec.jar, jai_core.jar, and
387 mlibwrapper_jai.jar</seg>
388 <seg>/opt/fop-&fop-version;</seg>
389 </seglistitem>
390 </segmentedlist>
391
392 <variablelist>
393 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
394 <?dbfo list-presentation="list"?>
395 <?dbhtml list-presentation="table"?>
396
397 <varlistentry id="fop-prog">
398 <term><command>fop</command></term>
399 <listitem>
400 <para>is a wrapper script to the <command>java</command> command
401 which sets up the <application>FOP</application>
402 environment and passes the required parameters.</para>
403 <indexterm zone="fop fop-prog">
404 <primary sortas="b-fop">fop</primary>
405 </indexterm>
406 </listitem>
407 </varlistentry>
408
409 <varlistentry id="fop.jar">
410 <term><filename class='libraryfile'>fop.jar</filename></term>
411 <listitem>
412 <para>contains all the <application>FOP</application>
413 <application>Java</application> classes.</para>
414 <indexterm zone="fop fop.jar">
415 <primary sortas="c-fop.jar">fop.jar</primary>
416 </indexterm>
417 </listitem>
418 </varlistentry>
419
420 </variablelist>
421
422 </sect2>
423
424</sect1>
Note: See TracBrowser for help on using the repository browser.