This is the mail archive of the
automake@gnu.org
mailing list for the automake project.
Re: Partially Linked Objects
- To: Olly Betts <olly@muscat.co.uk>
- Subject: Re: Partially Linked Objects
- From: Brian Ford <ford@vss.fsi.com>
- Date: Mon, 10 May 1999 12:54:56 -0500
- cc: automake@gnu.org
On 10 May 1999, Olly Betts wrote:
> Hi,
>
> I'm trying to use automake to build a partially linked object (ld -r on all
> the Unix platforms I need to support). I've tried a few variations along
> the lines of:
>
> noinst_DATA = partial.o
>
> partial_o_SOURCES = partial1.c partial2.c
>
> partial.o: $(partial_o_SOURCES)
> ld -o $@ -r $(partial_o_OBJECTS)
>
> But not had any success.
>
> Is there a way of doing this? In reality there are a couple of hundred
> sources, so I'm trying to avoid having to maintain a list of the sources and
> the objects separately. Any suggestions greatly appreciated.
>
Two suggestions. Use libtool convienence libraries, or do something like
this:
noinst_PROGRAMS = partial.o
partial_o_LDFLAGS = $(LDFLAGS) -r
partial_o_SOURCES = partial1.c partial2.c
--
Brian Ford
Software Engineer
Vital Visual Simulation Systems
FlightSafety International
Phone: 314-551-8460
Fax: 314-551-8444