source: clfs-sysroot/BOOK/final-system/common/man.xml@ 902b43c

Last change on this file since 902b43c was d11b860, checked in by Chris Staub <chris@…>, 18 years ago

Remove obsolete command from man instructions

  • Property mode set to 100644
File size: 8.3 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
3 "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6]>
7
8<sect1 id="ch-system-man" role="wrap">
9 <?dbhtml filename="man.html"?>
10
11 <title>Man-&man-version;</title>
12
13 <indexterm zone="ch-system-man">
14 <primary sortas="a-Man">Man</primary>
15 </indexterm>
16
17 <sect2 role="package">
18 <title/>
19
20 <para>The Man package contains programs for finding and viewing man
21 pages.</para>
22
23 </sect2>
24
25 <sect2 role="installation">
26 <title>Installation of Man</title>
27
28 <para os="a">A few adjustments need to be made to the sources of Man.</para>
29
30 <para os="b">First, a <command>sed</command> substitution is needed to
31 modify <command>configure</command>'s default search path for executables.
32 It cycles through the values in <envar>PREPATH</envar> until it finds the
33 program it is looking for. The <option>-R</option> switch is also added to
34 the <envar>PAGER</envar> variable so that escape sequences are properly
35 handled by Less:</para>
36
37<screen os="c"><userinput>cp configure{,.orig}
38sed -e "/PREPATH=/s@=.*@=\"$(eval echo ${CLFS}/{,usr/}{sbin,bin})\"@g" \
39 -e 's@-is@&amp;R@g' configure.orig &gt; configure</userinput></screen>
40
41 <para os="d">Another couple of <command>sed</command> substitutions
42 comment out the <quote>MANPATH /usr/man</quote> and
43 <quote>MANPATH /usr/local/man</quote> lines in the
44 <filename>man.conf</filename> file to prevent redundant
45 results when using programs such as <command>whatis</command>:</para>
46
47<screen os="e"><userinput>cp src/man.conf.in{,.orig}
48sed -e 's@MANPATH./usr/man@#&amp;@g' \
49 -e 's@MANPATH./usr/local/man@#&amp;@g' \
50 src/man.conf.in.orig &gt; src/man.conf.in</userinput></screen>
51
52 <para os="f">Prepare Man for compilation:</para>
53
54<screen os="g"><userinput>./configure -confdir=/etc</userinput></screen>
55
56 <variablelist os="h">
57 <title>The meaning of the configure options:</title>
58
59 <varlistentry>
60 <term><parameter>-confdir=/etc</parameter></term>
61 <listitem>
62 <para>This tells the <command>man</command> program to look for the
63 <filename>man.conf</filename> configuration file in the <filename
64 class="directory">/etc</filename> directory.</para>
65 </listitem>
66 </varlistentry>
67 </variablelist>
68
69 <para os="i">Configure was modified to look in <filename
70 class="directory">${CLFS}</filename> for the paths of helper
71 programs. Right now all of the programs have <filename
72 class="directory">${CLFS}</filename> as a prefix. Remove that prefix
73 with the following command:</para>
74
75<screen os="j"><userinput>cp conf_script{,.orig}
76sed "s@${CLFS}@@" conf_script.orig &gt; conf_script</userinput></screen>
77
78 <para os="k">Build makemsg using the hosts gcc. It is executed during the build:</para>
79
80<screen os="l"><userinput>gcc src/makemsg.c -o src/makemsg</userinput></screen>
81
82 <para os="m">Compile the package:</para>
83
84<screen os="n"><userinput>make</userinput></screen>
85
86 <para os="o">Install the package:</para>
87
88<screen os="p"><userinput>make DESTDIR=${CLFS} install</userinput></screen>
89
90 <note os="q">
91 <para>If you will be working on a terminal that does not support
92 text attributes such as color and bold, you can disable Select
93 Graphic Rendition (SGR) escape sequences by editing the
94 <filename>man.conf</filename> file and adding the <option>-c</option>
95 option to the <envar>NROFF</envar> variable. If you use multiple
96 terminal types for one computer it may be better to selectively add
97 the <envar>GROFF_NO_SGR</envar> environment variable for the terminals
98 that do not support SGR.</para>
99 </note>
100
101 <para os="r">If the character set of the locale uses 8-bit characters, search
102 for the line beginning with <quote>NROFF</quote> in
103 <filename>/etc/man.conf</filename>, and verify that it matches the
104 following:</para>
105
106<screen os="s">NROFF /usr/bin/nroff -Tlatin1 -mandoc</screen>
107
108 <para os="t">Note that <quote>latin1</quote> should be used even if it is not
109 the character set of the locale. The reason is that, according to the
110 specification, <command>groff</command> has no means of typesetting
111 characters outside International Organization for Standards (ISO) 8859-1
112 without some strange escape codes. When formatting man pages,
113 <command>groff</command> thinks that they are in the ISO 8859-1 encoding
114 and this <parameter>-Tlatin1</parameter> switch tells
115 <command>groff</command> to use the same encoding for output. Since
116 <command>groff</command> does no recoding of input characters, the f
117 ormatted result is really in the same encoding as input, and therefore
118 it is usable as the input for a pager.</para>
119
120 <para os="u">This does not solve the problem of a non-working
121 <command>man2dvi</command> program for localized man pages in
122 non-ISO 8859-1 locales. Also, it does not work with multibyte
123 character sets. The first problem does not currently have a solution.
124 The second issue is not of concern because the CLFS installation does
125 not support multibyte character sets.</para>
126
127 <para os="v">Additional information with regards to the compression of
128 man and info pages can be found in the BLFS book at
129 <ulink url="&blfs-root;view/svn/postlfs/compressdoc.html"/>.</para>
130
131 </sect2>
132
133 <sect2 id="contents-man" role="content">
134 <title>Contents of Man</title>
135
136 <segmentedlist>
137 <segtitle>Installed programs</segtitle>
138
139 <seglistitem>
140 <seg>apropos, makewhatis, man, man2dvi, man2html, and whatis</seg>
141 </seglistitem>
142 </segmentedlist>
143
144 <variablelist>
145 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
146 <?dbfo list-presentation="list"?>
147 <?dbhtml list-presentation="table"?>
148
149 <varlistentry id="apropos">
150 <term><command>apropos</command></term>
151 <listitem>
152 <para>Searches the <command>whatis</command> database and
153 displays the short descriptions of system commands that contain
154 a given string</para>
155 <indexterm zone="ch-system-man apropos">
156 <primary sortas="b-apropos">apropos</primary>
157 </indexterm>
158 </listitem>
159 </varlistentry>
160
161 <varlistentry id="makewhatis">
162 <term><command>makewhatis</command></term>
163 <listitem>
164 <para>Builds the <command>whatis</command> database; it reads all
165 the man pages in the <envar>MANPATH</envar> and writes the name
166 and a short description in the <command>whatis</command> database
167 for each page</para>
168 <indexterm zone="ch-system-man makewhatis">
169 <primary sortas="b-makewhatis">makewhatis</primary>
170 </indexterm>
171 </listitem>
172 </varlistentry>
173
174 <varlistentry id="man">
175 <term><command>man</command></term>
176 <listitem>
177 <para>Formats and displays the requested on-line man page</para>
178 <indexterm zone="ch-system-man man">
179 <primary sortas="b-man">man</primary>
180 </indexterm>
181 </listitem>
182 </varlistentry>
183
184 <varlistentry id="man2dvi">
185 <term><command>man2dvi</command></term>
186 <listitem>
187 <para>Converts a man page into dvi format</para>
188 <indexterm zone="ch-system-man man2dvi">
189 <primary sortas="b-man2dvi">man2dvi</primary>
190 </indexterm>
191 </listitem>
192 </varlistentry>
193
194 <varlistentry id="man2html">
195 <term><command>man2html</command></term>
196 <listitem>
197 <para>Converts a man page into HTML</para>
198 <indexterm zone="ch-system-man man2html">
199 <primary sortas="b-man2html">man2html</primary>
200 </indexterm>
201 </listitem>
202 </varlistentry>
203
204 <varlistentry id="whatis">
205 <term><command>whatis</command></term>
206 <listitem>
207 <para>Searches the <command>whatis</command> database and
208 displays the short descriptions of system commands that
209 contain the given keyword as a separate word</para>
210 <indexterm zone="ch-system-man whatis">
211 <primary sortas="b-whatis">whatis</primary>
212 </indexterm>
213 </listitem>
214 </varlistentry>
215
216 </variablelist>
217
218 </sect2>
219
220</sect1>
Note: See TracBrowser for help on using the repository browser.