On 13/04/18 07:59, Josh Soref wrote:> Randall S. Becker <rsbecker at nexbridge.com> wrote: > >> -REGRESSTMP = "$(PWD)/regress" >> +REGRESSTMP = `pwd` >> >> ? tests interop-tests t-exec unit: regress-prep regress-binaries >> $(TARGETS) >> > It looks like the problem is that pwd is in uppercase, not so much the > distinction between $() and ``. > > Can you confirm?I think not.? $(PWD) is a valid expansion of a shell variable when using bash, maybe also Bourne shell, whereas `pwd` is the output of the pwd command. There seems to be muddled-headed thinking going on with scripts. Recently there was a configure problem because of a difference between csh and sh.? (As I recall, csh exits the script when you use an undefined variable, whereas the various sh shells interpolate an empty string.)? It is madness to think you can take a program that was written for one language and run it using another.? I understand that a lot of unixy shells are very similar, and that if you take great care you really can run a script in all of them, but, if that is what is intended, then there should be a document that describes which features are allowed to be used and which are not; better yet, a program to validate the scripts. I think, better yet, is to mandate use of a specific shell.? The bash shell might be the most widely available.
-----Original Message----- From: openssh-unix-dev <openssh-unix-dev-bounces+scott_n=xypro.com at mindrot.org> On Behalf Of David Newall> I think not.? $(PWD) is a valid expansion of a shell variable when using bash, maybe also Bourne shell, whereas >`pwd` is the output of the pwd command.Isn't $(PWD) a command substitution in bash? ${PWD} is shell variable expansion.
On April 13, 2018 11:13 AM, Scott Neugroschl wrote:> -----Original Message----- > From: openssh-unix-dev <openssh-unix-dev- > bounces+scott_n=xypro.com at mindrot.org> On Behalf Of David Newall > > I think not.? $(PWD) is a valid expansion of a shell variable when usingbash,> maybe also Bourne shell, whereas >`pwd` is the output of the pwd > command. > > Isn't $(PWD) a command substitution in bash? ${PWD} is shell variable > expansion.Hi Scott, $(PWD) is evaluated in supposed to be a make evaluation, while ${PWD} is a bash/ksh eval. I'm still investigating whether this is a coreutils issue. () in bash/ksh is a sub-shell invocation so would be really bad or chaotic if that was passed in. Cheers, Randall
On 14/04/18 00:42, Scott Neugroschl wrote:> From: openssh-unix-dev <openssh-unix-dev-bounces+scott_n=xypro.com at mindrot.org> On Behalf Of David Newall >> I think not.? $(PWD) is a valid expansion of a shell variable when using bash, maybe also Bourne shell, whereas >`pwd` is the output of the pwd command. > Isn't $(PWD) a command substitution in bash? ${PWD} is shell variable expansion.Yes.? I was confused.