xref: /original-bsd/usr.bin/ranlib/ranlib.1 (revision b001ed0c)
1.\" Copyright (c) 1990 Regents of the University of California.
2.\" All rights reserved.  The Berkeley software License Agreement
3.\" specifies the terms and conditions for redistribution.
4.\"
5.\"     @(#)ranlib.1	6.3 (Berkeley) 06/26/90
6.\"
7.Dt RANLIB 1
8.Os ATT 7th
9.Sh NAME
10.Nm ranlib
11.Nd convert archives to random libraries
12.Sh SYNOPSIS
13.Nm ranlib
14.Op Fl t
15.Ar archive ...
16.Sh DESCRIPTION
17.Nm Ranlib
18converts each
19.Ar archive
20to a form which the loader can load more rapidly.
21.Nm Ranlib
22does this by adding a table of contents called
23.Sy \&__.SYMDEF
24to the beginning of the archive.
25.Nm Ranlib
26uses
27.Xr ar  1
28to reconstruct the archive, so that sufficient temporary file space must
29be available in the file system which contains the current directory.
30.Pp
31.Tp Fl t
32Ranlib only "touches" the archives and does not modify them.
33This is useful after copying an archive
34or using the
35.Fl t
36option of
37.Xr make  1
38in order to avoid having
39.Xr ld  1
40complain about
41an
42.Dq out of date
43symbol table.
44.Tp
45.Sh SEE ALSO
46.Xr ld 1 ,
47.Xr ar 1 ,
48.Xr lorder 1 ,
49.Xr make 1
50.Sh HISTORY
51.Nm Ranlib
52appeared in Version 7 AT&T UNIX.
53.Sh BUGS
54Because generation of a library by
55.Xr ar
56and randomization of the library by
57.Nm ranlib
58are separate processes, phase errors are possible.  The loader,
59.Xr ld  ,
60warns when the modification date of a library is more recent than the
61creation date of its dictionary;  but this means that you get the
62warning even if you only copy the library.
63