xref: /original-bsd/usr.sbin/config.new/config.8 (revision b4971bb3)
1.\" Copyright (c) 1980, 1991, 1993
2.\"	The Regents of the University of California.  All rights reserved.
3.\"
4.\" %sccs.include.redist.man%
5.\"
6.\"     @(#)config.8	8.1 (Berkeley) 06/06/93
7.\"
8.Dd
9.Dt CONFIG 8
10.Os BSD 4
11.Sh NAME
12.Nm config
13.Nd build kernel compilation directories
14.Sh SYNOPSIS
15.Nm config
16.Op Fl p
17.Ar system-name
18.Sh DESCRIPTION
19.Pp
20.Nm Config
21builds a set of configuration files from the file
22.Ar system-name ,
23which describes
24the system to configure.
25.Pp
26.Nm Config
27should run from the
28.Pa conf
29subdirectory of the top-level machine-specific directory
30of the system source (usually
31.Pa /sys/MACHINE/conf ,
32where
33.Pa MACHINE
34is one of
35.Pa vax ,
36.Pa tahoe ,
37.Pa hp300 ,
38and so forth).
39.Nm Config
40assumes the directory
41.Pa ../../compile
42exists; it places all output files in a subdirectory there,
43creating the subdirectory if necessary.
44The subdirectory name is taken from the
45.Ar system-name ;
46thus, configuring with
47.Dq Li config PICKLE
48will use the directory
49.Pa ../../compile/PICKLE .
50.Pp
51If the
52.Fl p
53option is supplied,
54.Pa .PROF
55is appended to the compilation directory name, and
56.Nm config
57acts as if the lines
58.Dq Li makeoptions PROF="-pg"
59and
60.Dq Li options GPROF
61appeared in the configuration file.
62This will build a system that includes profiling code; see
63.Xr kgmon 8
64and
65.Xr gprof 1 .
66The
67.Fl p
68flag is expected to be used for
69.Dq one-shot
70profiles of existing systems;
71for regular profiling,
72it is probably wiser to make a separate configuration
73containing the
74.Li makeoptions
75line.
76.Pp
77The old undocumented
78.Fl g
79flag is no longer supported.
80Instead, use
81.Dq Li makeoptions DEBUG="-g"
82and (typically)
83.Dq Li options KGDB .
84.Pp
85The output of
86.Nm config
87consists of a number of files, principally
88.Pa ioconf.c ,
89a description of I/O devices that may be attached to the system; and a
90.Pa Makefile ,
91used by
92.Xr make 1
93in building the kernel.
94.Pp
95After running
96.Nm config ,
97it is wise to run
98.Dq Li make depend
99in the directory where the new makefile
100was created.
101.Nm Config
102prints a reminder of this when it completes.
103.Pp
104If
105.Nm config
106stops due to errors, the problems reported should be corrected and
107.Nm config
108should be run again.
109.Nm Config
110attempts to avoid changing the compilation directory
111if there are configuration errors,
112but this code is not well-tested,
113and some problems (such as running out of disk space)
114are unrecoverable.
115.Sh SEE ALSO
116The SYNOPSIS portion of each device in section 4.
117.Rs
118.%T "Building 4.4 BSD Systems with Config"
119.\" .%T "Device Support in 4.4BSD"
120.Re
121.Sh HISTORY
122The
123.Nm
124command appeared in
125.Bx 4.1 .
126It was completely revised in
127.Bx 4.4 .
128