This is the mail archive of the mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Shell brace expansion in make works?

William A. Gatliff wrote:
I have a Makefile with a command like this:

 mkdir -p /opt/billgatliff/{usr,lib}

Works fine under Linux, but not on the latest Cygwin.

Under Cygwin, what I actually get is a directory called "{usr",
instead of "usr".  Other variations on this brace expansion (in tar
arguments, etc.) produce similar problems.

I checked this:

$ set | grep SHELL

Seems fine.  But when I do this:

$ make SHELL=/bin/sh ...
                    ^^ "bash"
I actually get what I'm after, i.e. "usr" instead of "{usr".
I'm guessing that you meant to type "bash" in the email. Either way, cygwin make seems to ignore the environment variable SHELL, and uses '/bin/sh' unless you specify on the command-line or in the makefile.

I was able to reproduce this.

Use this as a makefile
echo a{1,2}

Then run "make" and it will output "a{1,2}", but if you run "make SHELL=/bin/bash" it will output "a1 a2".


Unsubscribe info:
Bug reporting:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]