Re: [PATCH] out-of-tree builds

From: Geert Uytterhoeven
Date: Mon Mar 15 2004 - 13:15:38 EST


On Mon, 15 Mar 2004, Sam Ravnborg wrote:
> On Mon, Mar 15, 2004 at 01:41:02PM +0100, Geert Uytterhoeven wrote:
> > Unfortunately not everything works.
> >
> > E.g. I need to build usr/ with a different (newer) binutils, so when the build
> > fails on assembling usr/initramfs_data.o, I used to do the following, which no
> > longer works:
> >
> > | tux$ PATH=/usr/bin/:$PATH make usr/
> > | make: `usr/' is up to date.
> > | tux$
> >
> > I guess I need a catch-all .PHONY rule, but don't know how to implement it...
>
> Try:
> .PHONY: $(MAKECMDGOALS)

Thanks! But it doesn't work:

| tux$ rm usr/*
| tux$ make usr/
| make: Nothing to be done for `usr/'.
| tux$

> or eventually
> ifneq ($(MAKECMDGOALS),)
> .PHONY: $(MAKECMDGOALS)
> endif
>
> The latter if an empty .PHONY is not allowed.

It's allowed.

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/