xref: /netbsd-src/libexec/makewhatis/makewhatis.8 (revision e5548b402ae4c44fb816de42c7bba9581ce23ef5)
1.\"	$NetBSD: makewhatis.8,v 1.11 2005/04/04 08:13:27 wiz Exp $
2.\"
3.\" Copyright (c) 1997, 2002 The NetBSD Foundation, Inc.
4.\" All rights reserved.
5.\"
6.\" This code is derived from software contributed to The NetBSD Foundation
7.\" by Robert Dobbs <banshee@gabriella.resort.com>.
8.\"
9.\" Redistribution and use in source and binary forms, with or without
10.\" modification, are permitted provided that the following conditions
11.\" are met:
12.\" 1. Redistributions of source code must retain the above copyright
13.\"    notice, this list of conditions and the following disclaimer.
14.\" 2. Redistributions in binary form must reproduce the above copyright
15.\"    notice, this list of conditions and the following disclaimer in the
16.\"    documentation and/or other materials provided with the distribution.
17.\" 3. All advertising materials mentioning features or use of this software
18.\"    must display the following acknowledgement:
19.\"        This product includes software developed by the NetBSD
20.\"        Foundation, Inc. and its contributors.
21.\" 4. Neither the name of The NetBSD Foundation nor the names of its
22.\"    contributors may be used to endorse or promote products derived
23.\"    from this software without specific prior written permission.
24.\"
25.\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
26.\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
27.\" TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
28.\" PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
29.\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
30.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
31.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
32.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
33.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
34.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
35.\" POSSIBILITY OF SUCH DAMAGE.
36.\"
37.Dd April 3, 2005
38.Dt MAKEWHATIS 8
39.Os
40.Sh NAME
41.Nm makewhatis
42.Nd create a whatis.db database
43.Sh SYNOPSIS
44.Nm /usr/libexec/makewhatis
45.Op Fl fw
46.Op Fl C Ar file
47.Op Ar manpath ...
48.Sh DESCRIPTION
49.Nm
50strips the NAME lines from compiled or raw
51.Xr man 1
52pages and creates a whatis.db database for use in
53.Xr apropos 1 ,
54.Xr whatis 1 ,
55or with
56.Xr man 1 Ns 's
57.Fl k
58option.
59Man pages compressed with
60.Xr compress 1
61and
62.Xr gzip 1
63are uncompressed before processing.
64.Pp
65When
66.Ar manpath
67is provided multiple times, the resulting database file
68is generated in the first directory specified, and contains
69entries for all the directories.
70.Pp
71If
72.Ar manpath
73is not provided,
74.Nm
75parses
76.Pa /etc/man.conf
77and regenerates the whatis database files specified there.
78Each database file is assumed to reside in the root of the appropriate
79man page hierarchy.
80.Pp
81The options are as follows:
82.Bl -tag -width XCXfileXX
83.It Fl C Ar file
84Use
85.Ar file
86(in
87.Xr man.conf 5
88format) as configuration file instead of the default,
89.Pa /etc/man.conf .
90.It Fl f
91Don't spawn child processes to generate the individual database files,
92but do all the work synchronously in the foreground.
93.It Fl w
94Print warnings about input files we don't like.
95.El
96.Sh FILES
97.Bl -tag -compact -width /etc/man.conf1
98.It Pa whatis.db
99name of the whatis database
100.It Pa /etc/man.conf
101.Xr man 1
102configuration file, used to get the location of the whatis databases when
103.Nm
104is called without arguments
105.El
106.Sh SEE ALSO
107.Xr apropos 1 ,
108.Xr man 1 ,
109.Xr whatis 1 ,
110.Xr man.conf 5
111.Sh HISTORY
112.An -nosplit
113.Nm
114first appeared in
115.Nx 1.0 ,
116as a shell script written by
117.An J.T. Conklin Aq jtc@NetBSD.org
118and
119.An Thorsten Frueauf Aq frueauf@ira.uka.de .
120Further work was done by
121.An Matthew Green ,
122.An Luke Mewburn ,
123and
124.An Chris Demetriou .
125.Pp
126.An Matthias Scheler
127has reimplemented
128.Nm
129in C in
130.Nx 1.5 .
131.Sh AUTHORS
132.An Matthias Scheler Aq tron@NetBSD.org
133