Re: [PATCH] Fix cygwin install issues

2 messages, 2 authors, 2016-06-15 · open the first message on its own page

Re: [PATCH] Fix cygwin install issues

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:42:08

"H. Peter Anvin" [off-list ref] writes:
quoted
...  I suspect it might be
the responsibility of the user to quote them if she chooses to
set bindir or DESTDIR to a funky value, like this:
    $ make bindir="'My Documents\Programs'"
I don't think that's the right approach.

	$(INSTALL) -d -m755 '$(DESTDIR)$(bindir)'

... at least handles everything except embedded single quotes.
OK.  It is better than dq, and the user can still work it around
like this if she really wanted to:

	make bindir="Anna'\\''s Home/bin"

I wish we had $(shellquote $(DESTDIR)$(bindir)) in make ;-).

Re: [PATCH] Fix cygwin install issues

From: "H. Peter Anvin" <hpa@zytor.com>
Date: 2016-06-15 22:42:08

Junio C Hamano wrote:
OK.  It is better than dq, and the user can still work it around
like this if she really wanted to:

	make bindir="Anna'\\''s Home/bin"

I wish we had $(shellquote $(DESTDIR)$(bindir)) in make ;-).
Hmm... let's think about this for a second...

shellquote = '$(subst ','\'',$(1))'

$(call shellquote,$(whatever))

... seems to work just fine.

(No need to worry about ! since Make commands are always /bin/sh.)

	-hpa
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help