[Top][All Lists]

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

Re: $(file ...) function and other tools writing to the same file

From: Tim Murphy
Subject: Re: $(file ...) function and other tools writing to the same file
Date: Mon, 14 Mar 2016 15:11:24 +0000

On 14 March 2016 at 14:55, Martin Reinders <address@hidden> wrote:

> On 14.03.16 14:56, Tim Murphy wrote:
> > Functions and variables are expanded before the command and list of
> > variables is sent to the shell to be executed.  Hence $(file) happens
> > before your echo command is executed.
> That makes sense now, thank you very much.
> > Why would you use $(file) in a commandline anyhow?
> Well, my idea was to use $(file) as a replacement for the "echo" command
> in a Makefile which is used both on Unix and Windows, since the
> escaping/quoting rules are a bit different between those platforms.
> Your and Paul's feedback helped a lot to understand the problem, and I
> will now probably refrain from using $(file) for _that_ purpose.
That's a great reason for wanting to do that. I certainly think it would be
immensely useful if make had some sort of very limited shell that would
allow x-platform makefiles to be created without a lot of ifdefs or special



reply via email to

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