source: INSTALL@ 30ae6314

10.0 10.0-rc1 10.1 10.1-rc1 11.0 11.0-rc1 11.0-rc2 11.0-rc3 11.1 11.1-rc1 11.2 11.2-rc1 11.3 11.3-rc1 12.0 12.0-rc1 12.1 12.1-rc1 6.0 6.1 6.1.1 6.3 6.4 6.5 6.6 6.7 6.8 7.0 7.1 7.2 7.3 7.4 7.5 7.5-systemd 7.6 7.6-systemd 7.7 7.7-systemd 7.8 7.8-systemd 7.9 7.9-systemd 8.0 8.1 8.2 8.3 8.4 9.0 9.1 arm bdubbs/gcc13 ml-11.0 multilib renodr/libudev-from-systemd s6-init trunk v3_0 v3_1 v3_2 v3_3 v4_0 v4_1 v5_0 v5_1 v5_1_1 xry111/arm64 xry111/arm64-12.0 xry111/clfs-ng xry111/lfs-next xry111/loongarch xry111/loongarch-12.0 xry111/loongarch-12.1 xry111/mips64el xry111/pip3 xry111/rust-wip-20221008 xry111/update-glibc
Last change on this file since 30ae6314 was 30ae6314, checked in by Gerard Beekmans <gerard@…>, 23 years ago

Added note that Links can be used as well
Fixed minor typo (installed->installing)

git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@664 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689

  • Property mode set to 100644
File size: 4.2 KB
Line 
1Ok, so you have downloaded the XML source. Now what? You are probably
2wanting to convert these XML files to easier to read HTML, PS, PDF, txt
3or other formatted files. All that can be read below.
4
5Let's start by downloading some software.
6
7If all you want to do is being able to convert XML to HTML download the
8following:
9
10OpenJade - http://openjade.sourceforge.net
11DocBook-XML DTD - http://www.docbook.org/xml/4.1.2/
12DSSSL DocBook Stylesheets - http://www.nwalsh.com/docbook/dsssl/
13
14As the DocBook DTD and Stylesheets are made available as a zip achives you
15may need to download the unzip package as well if your Linux system doesn't
16have one:
17
18Unzip - ftp://ftp.info-zip.org/pub/infozip/src/
19
20If you want to be able to convert the book into PS and PDF as well I
21recommend using the Htmldoc program. This takes a html file (created
22with openjade which you already downloaded) and converts it to PS or
23PDF:
24
25HTMLDOC - http://www.easysw.com/htmldoc/
26FLTK (X front-end) - http://sourceforge.net/projects/fltk
27
28If you want to be able to convert the book into TXT as well I recommend
29using lynx to convert HTML to TXT using the -dump option to lynx. There
30are most likely better programs to do this, but Lynx is often installed
31on systems anyways (as a console based web browser). Another often used
32console based browser is Links which can be used in the same way as
33Lynx.
34
35Lynx - http://lynx.browser.org
36Links - http://artax.karlin.mff.cuni.cz/~mikulas/links/
37
38You have everything you need now. Let's install this stuff.
39
40Create the /usr/share/docbook directory, cd into it and unpack the
41docbook-xml dtd archive there.
42
43Create the /usr/share/dsssl directory, cd into it and unpack the dsssl
44stylesheet archive in there. Now copy the lfs.dsl file you will find in
45the LFS-BOOK XML archive into /usr/share/dsssl/docbook/html
46
47The last step is installing OpenJade.
48
49In order for openjade to be able to convert the DocBook based documents
50into other formats, it needs to know where the DocBook DTD related
51files are located. This is sort of the DocBook equivalent for the $PATH
52variable. You have two ways of doing this:
53
541) You can set the $SGML_CATALOG_FILES variable and include the full
55paths to the catalog files in it
56 or
572) You can hard-code the paths into the openjade binary.
58
59If you choose option 1, add the following to your bash configuration
60file, system wide profile or wherever you wish to include it:
61
62export SGML_CATALOG_FILES=/usr/share/docbook/docbook.cat:/usr/share/dsssl/docbook/catalog:/usr/share/dsssl/openjade/catalog
63
64Followed by installing openjade by running:
65 ./configure --prefix=/usr
66 make
67 make install
68 cp -av dsssl /usr/share/dsssl/openjade
69
70If you choose option 2, install OpenJade as follows:
71
72 ./configure --prefix=/usr \
73 > --enable-default-catalog=/usr/share/docbook/docbook.cat:/usr/share/dsssl/docbook/catalog:/usr/share/dsssl/openjade/catalog
74 make
75 make install
76 cp -av dsssl /usr/share/dsssl/openjade
77
78And you don't have to worry about the $SGML_CATALOG_FILES variable in
79this case.
80
81
82You're all set to convert XML to HTML (among a few other formats
83supported by openjade) now. If you want to convert to PS and PDF as
84well, install the following two packages.
85
86FLTK (you can skip this one if you don't want the X front-end):
87 ./configure --prefix=/usr
88 make
89 make install
90
91HTMLDOC:
92Edit the Makefile.in file and find these lines:
93
94install:
95 $(MAKE) all
96 for dir in $(INSTALLDIRS); do\
97 echo Installing in $$dir...;\
98 (cd $$dir; $(MAKE) -$(MAKEFLAGS) clean) || break;\
99 done
100
101Change this into:
102
103install:
104 $(MAKE) all
105 for dir in $(INSTALLDIRS); do\
106 echo Installing in $$dir...;\
107 (cd $$dir; $(MAKE) -$(MAKEFLAGS) install) || break;\
108 done
109
110This will fix that little bug that causes 'make install' to be
111identical to 'make clean'. Now continue with:
112
113 ./configure --prefix=/usr
114 make
115 make install
116
117
118
119The last package is Lynx which will be used for the HTML to TXT
120conversion. Install it by running:
121
122 ./configure --prefix=/usr
123 make
124 make install
125
126There, all set now. Go back to the README file for some examples how to
127convert this XML to the various other formats.
128
Note: See TracBrowser for help on using the repository browser.