Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10.1 6/24/83; site alice.UUCP
Path: utzoo!linus!philabs!cmcl2!seismo!lll-crg!dual!qantel!ihnp4!mhuxn!mhuxr!ulysses!allegra!alice!ark
From: ark@alice.UUCP (Andrew Koenig)
Newsgroups: net.unix
Subject: Re: using libraries with ld (1)
Message-ID: <4122@alice.UUCP>
Date: Fri, 9-Aug-85 11:00:35 EDT
Article-I.D.: alice.4122
Posted: Fri Aug  9 11:00:35 1985
Date-Received: Tue, 13-Aug-85 02:29:48 EDT
References: <240@cmu-cs-h.ARPA>
Organization: Bell Labs, Murray Hill
Lines: 18

>> Some versions of "ld" support the "-Llibpath" option to specify an
>> additional directory to search for libraries.
>> 
>> You can always just name the library in the "ld" or "cc" command:
>> 	cc -o myprog myprog.o mysub.o mylib.a -lm -lplot

> I was under the impression that libraries specified in the way that mylib.a
> is have the entire library linked in rather than just those routines which
> are needed because of undefined identifiers.  Does anyone know if this is
> actually the case?

>				Rick Busdiecker
>				rfb@cmu-cs-h.arpa

It is not actually the case.

When you name a library as an argument to ld, it picks out
only the components it needs.