ar - the archiver
Robert Skinner
robert at texas.esd.sgi.com
Fri Mar 2 04:30:22 AEST 1990
In article <9002281129.aa20377 at SMOKE.BRL.MIL>, JORDAN at gmr.COM writes:
> Can someone give me any tips on using ar, or lead me to any books that
> might be able to help me.
>
> I am able to create a library, add objects, and update symbol tables
> (e.g. ar cr lib.a a.o b.o, or ar ts lib.a), BUT I would like the compilerr
> to recognize it via a flag; for example, the way it recognizes -Zg, or
-lgl_s.
>
> Thanks for any help...
>
> tp mugabi-jordan
Look at the -L option in the man page for 'ld'. It allows you to set
the directories 'ld' will use to search for libraries you have named
with -L. For example, you can name your library libmylib.a, put it in
/usr/people/me/lib, and then have a link line that looks like
cc ..... -L/usr/people/me/lib ... -lmylib
(cc just calls ld to link.) This isn't much help for just one private
library, but its great if you have several.
The -Zg option is obsolete on 4D systems and should not be used. It is
equivalent to using '-lgl -lm' in the link command. Besides, explicitly
saying -lgl makes it easier to change to -lgl_s and back.
Robert Skinner
robert at sgi.com
Whoa Homer, don't have a cow.
- Bart Simpson
More information about the Comp.sys.sgi
mailing list