On 2001/04/09 20:50:00 -0400, Paul D. Smith wrote:

> %% [EMAIL PROTECTED] writes:
> 
>   c> VAL := $@
> 
> This can't work, since ":=" means "immediate evaluation" and when this
> line is read in by make, the value of the variable $@ is empty (of
> course, since it only has a value within a rule context).
> 
>   c> %: VAL := $@
> 
> Ditto here; why do you want to use ":=" instead of just "=" here?
> 
>   c> LIST := a b c
>   c> $(LIST): echo-val
>   c> echo-val: ; @echo VAL = $(VAL)
> 
> I guess I'm not sure _what_ you're trying to do; maybe a little context
> or description about the results you're looking for would help.

It looks pretty weird huh?

Well, here's what I've done explicitly in the past, and am now trying to
find some clean rules to do instead.  Sure, there are other ways to do
this, 

> make install-host1
building in /somedir/host1/
[etc...]

So if I have:

HOSTS := host1 host2 host3
INSTALL_HOSTS := $(addprefix install-,$(HOSTS))

# Here's my "goal"
$(INSTALL_HOSTS) : $(INSTALL_DIR) := $(subst install-,$(NULL),$@)
$(INSTALL_HOSTS) : install-all

install-all:
        copy foobar /somedir/$(INSTALL_DIR)



_______________________________________________
Help-make mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/help-make

Reply via email to