Re: [PATCH] Use SHELL_PATH from build system in run_command.c:prepare_shell_cmd
From: Junio C Hamano <hidden>
Date: 2016-06-15 22:53:26
Jonathan Nieder [off-list ref] writes:
quoted hunk
Sorry I forgot to send this before. Quick tweaks: - let assembler listings (from "make run-command.s") and sparse checks reflect the SHELL_PATH setting, too - the entire -DFOO="bar" argument is surrounded with single quotes in other EXTRA_CPPFLAGS settings, so let this one follow that pattern to avoid standing outdiff --git i/Makefile w/Makefile index dea1f157..a3791139 100644 --- i/Makefile +++ w/Makefile@@ -1913,7 +1913,8 @@ builtin/help.sp builtin/help.s builtin/help.o: EXTRA_CPPFLAGS = \ '-DGIT_MAN_PATH="$(mandir_SQ)"' \ '-DGIT_INFO_PATH="$(infodir_SQ)"' -run-command.o: EXTRA_CPPFLAGS = -DSHELL_PATH='"$(SHELL_PATH_SQ)"' +run-command.sp run-command.s run-command.o: EXTRA_CPPFLAGS = \ + '-DSHELL_PATH="$(SHELL_PATH_SQ)"' $(BUILT_INS): git$X $(QUIET_BUILT_IN)$(RM) $@ && \
Actually, I do not think this is sufficient, and it happens that you and I are the best position to realize it ;-). Look at what is done in the Makefile for DEFAULT_EDITOR and DEFAULT_PAGER, and compare with what the above is doing, and think why the EDITOR/PAGER needs to have another level of quoting.