help-make
[Top][All Lists]
Advanced

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

variable modifier within a for loop - How?


From: Shawn Honess
Subject: variable modifier within a for loop - How?
Date: Thu, 27 Jan 2005 17:54:00 -0800

Hi,

I'd like to do something like this...

    SRC = ./one/foo.c ./two/bar.c
    target:
        for file in $(SRC) ; do \
         $(HACK) < $$file > ./log/$$(basename file).log

to produce the commands...

    hack < ./one/foo.c > ./log/foo.c.log
    hack < ./two/bar.c > ./log/bar.c.log


Double $ kills all my ideas, and I can find nothing by
searching the internet!

Thanks for your help!
Cheers!
- Shawn
address@hidden <<== Please Reply to




reply via email to

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