From a48a55a73481713415ed7c5b4267e9b4f9b48cbc Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Mon, 15 Jul 2024 19:41:35 -0700 Subject: [PATCH] Quote BIN_DESTDIR better * Makefile.in (BIN_DESTDIR, install-eln, uninstall): * src/Makefile.in ($(pdmp)): Be more consistent about quoting BIN_DESTDIR and ELN_DESTDIR, avoiding double-quoting ''like this'' which does not work as expected. (cherry picked from commit a826296cff6ac1c636db83ff66199c60b69cdeb3) --- Makefile.in | 10 +++++----- src/Makefile.in | 6 +++--- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Makefile.in b/Makefile.in index d80e13e441f..9e890ec6c24 100644 --- a/Makefile.in +++ b/Makefile.in @@ -361,10 +361,10 @@ COPYDIR = ${srcdir}/etc ${srcdir}/lisp COPYDESTS = "$(DESTDIR)${etcdir}" "$(DESTDIR)${lispdir}" ifeq (${ns_self_contained},no) -BIN_DESTDIR='$(DESTDIR)${bindir}/' +BIN_DESTDIR = $(DESTDIR)${bindir}/ ELN_DESTDIR = $(DESTDIR)${libdir}/emacs/${version}/ else -BIN_DESTDIR='${ns_appbindir}/' +BIN_DESTDIR = ${ns_appbindir}/ ELN_DESTDIR = ${ns_applibdir}/ endif @@ -915,8 +915,8 @@ install-etc: install-eln: lisp ifeq ($(HAVE_NATIVE_COMP),yes) umask 022 ; \ - find native-lisp -type d -exec $(MKDIR_P) "$(ELN_DESTDIR){}" \; ; \ - find native-lisp -type f -exec ${INSTALL_ELN} "{}" "$(ELN_DESTDIR){}" \; + find native-lisp -type d -exec $(MKDIR_P) '$(ELN_DESTDIR){}' \; ; \ + find native-lisp -type f -exec ${INSTALL_ELN} '{}' '$(ELN_DESTDIR){}' \; endif ### Build Emacs and install it, stripping binaries while installing them. @@ -931,7 +931,7 @@ uninstall: uninstall-$(NTDIR) uninstall-doc uninstall-gsettings-schemas rm -f "$(DESTDIR)$(includedir)/emacs-module.h" $(MAKE) -C lib-src uninstall -unset CDPATH; \ - for dir in "$(DESTDIR)${lispdir}" "$(DESTDIR)${etcdir}" "$(ELN_DESTDIR)" ; do \ + for dir in "$(DESTDIR)${lispdir}" "$(DESTDIR)${etcdir}" '$(ELN_DESTDIR)' ; do \ if [ -d "$${dir}" ]; then \ case `cd "$${dir}" ; pwd -P` in \ "`cd ${srcdir} ; pwd -P`"* ) ;; \ diff --git a/src/Makefile.in b/src/Makefile.in index 7575ecbd07a..c278924ef94 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -682,7 +682,7 @@ endif ifeq ($(DUMPING),pdumper) $(pdmp): emacs$(EXEEXT) $(lispsource)/loaddefs.el $(lispsource)/loaddefs.elc LC_ALL=C $(RUN_TEMACS) -batch $(BUILD_DETAILS) -l loadup --temacs=pdump \ - --bin-dest $(BIN_DESTDIR) --eln-dest $(ELN_DESTDIR) + --bin-dest '$(BIN_DESTDIR)' --eln-dest '$(ELN_DESTDIR)' cp -f $@ $(bootstrap_pdmp) endif @@ -975,7 +975,7 @@ NATIVE_COMPILATION_AOT = @NATIVE_COMPILATION_AOT@ find $@ -name '*.eln' | rebase -v -O -T -; \ fi; \ LC_ALL=C $(RUN_TEMACS) -batch $(BUILD_DETAILS) -l loadup --temacs=pdump \ - --bin-dest $(BIN_DESTDIR) --eln-dest $(ELN_DESTDIR) \ + --bin-dest '$(BIN_DESTDIR)' --eln-dest '$(ELN_DESTDIR)' \ && cp -f emacs$(EXEEXT) bootstrap-emacs$(EXEEXT) \ && cp -f $(pdmp) $(bootstrap_pdmp); \ if test $(NATIVE_COMPILATION_AOT) = yes; then \ @@ -1014,7 +1014,7 @@ ifeq ($(DUMPING),pdumper) $(bootstrap_pdmp): bootstrap-emacs$(EXEEXT) rm -f $@ $(RUN_TEMACS) --batch $(BUILD_DETAILS) -l loadup --temacs=pbootstrap \ - --bin-dest $(BIN_DESTDIR) --eln-dest $(ELN_DESTDIR) + --bin-dest '$(BIN_DESTDIR)' --eln-dest '$(ELN_DESTDIR)' @: Compile some files earlier to speed up further compilation. @: First, byte compile these files, .... ANCIENT=yes $(MAKE) -C ../lisp compile-first EMACS="$(bootstrap_exe)" -- 2.39.5