[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Overriding all commands in

From: NightStrike
Subject: Re: Overriding all commands in
Date: Fri, 10 Aug 2007 12:18:22 -0400

On 8/10/07, Bernd Jendrissek <address@hidden> wrote:
> On 8/10/07, NightStrike <address@hidden> wrote:
> > For a particular project, there are a handful of .c files that need to
> > be compiled to .o files and installed as .o files, not linked into any
> > executable.  I came up with this ugly workaround:
> How about something like:
> startupdir = $(libdir)/nightstrike
> # Abusing the notion of "scripts" here...
> startup_SCRIPTS = crt1.o crt2.o crtspecialflags.o
> crtspecialflags_o_CFLAGS = $(AM_CFLAGS) $(CFLAGS) -fspecial-flag
> Then you let make figure out how to build the objects from C sources
> via the implicit .c.o: rule.

Overloading _SCRIPTS is similar to what I did with overloading
BUILT_SOURCES. I'm still left with the issue that crt1.o and crt2.o
are not built from crt1.c and crt2.c.

Perhaps I could use BUILT_SOURCES for its real intent and actually
create crt1.c and crt2.c from crtexe.c by simply doing:

    cp crtexe.c $@

But even there, I'm left with the original issue that I then need to
compile crt1 and 2.c into crt1.o and crt2.o.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]