ranlib (was: Gwyn's Directory Library)

Doug Gwyn gwyn at smoke.BRL.MIL
Sat Nov 19 05:23:26 AEST 1988


In article <283 at ontenv.UUCP> soley at ontenv.UUCP (Norman S. Soley) writes:
>... The documentation says that you can add
>the object files to the libc.a library (fine OK, I can do this) but
>then says some systems may require a rebuild of the symbol table after
>doing that and suggests ranlib (which I don't have), I've RTFMed for
>ar and ld and can see no answers there, any suggestions?

Unless the linker complains about the archive (libc.a) symbol table
being out of date, you don't need to do anything about it.  I know
of four object archive schemes in use on UNIX variants:
	1.  No symbol table.  In this case, be sure the added modules
	occur physically before any other external data or functions
	they reference.
	2.  Automatic symbol table maintenance when an object module
	is added to the archive.  AT&T's recent releases of UNIX System
	V take this approach, although not every system derived from
	those releases uses it.
	3.  Manual symbol table update via "ar ts".  I've only seen
	this on Silicon Graphics Iris workstations but it may be used
	elsewhere.
	4.  Manual symbol table update via "ranlib".  This is usually
	the case for systems derived from a Berkeley release.  I think
	"ranlib" originated on 7th Edition UNIX.  It's a pain.



More information about the Comp.unix.questions mailing list