summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGlenn Morris <rgm@gnu.org>2012-05-01 23:53:21 -0700
committerGlenn Morris <rgm@gnu.org>2012-05-01 23:53:21 -0700
commita36e64d04bd36f982cd82dfbc4eba8bf5d79cb06 (patch)
treeeb05c8804f4c4932281a5297758e2d4a2597171c
parent3fef57a2f66ec269f8ed016ad5bf39f2346c6b54 (diff)
downloademacs-a36e64d04bd36f982cd82dfbc4eba8bf5d79cb06.tar.gz
emacs-a36e64d04bd36f982cd82dfbc4eba8bf5d79cb06.tar.bz2
emacs-a36e64d04bd36f982cd82dfbc4eba8bf5d79cb06.zip
Makefile.in fix for systems without /bin/install or somesuch
* Makefile.in (install-arch-indep, uninstall): Ensure that INSTALL-type commands are run from top-level.
-rw-r--r--ChangeLog3
-rw-r--r--Makefile.in12
2 files changed, 13 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 46dff7c807f..2abe4a131c5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2012-05-02 Glenn Morris <rgm@gnu.org>
+ * Makefile.in (install-arch-indep, uninstall):
+ Ensure that INSTALL-type commands are run from top-level.
+
* Makefile.in (INFO_FILES): Add emacs-gnutls; accidentally
omitted from 2012-04-12 backport from trunk.
diff --git a/Makefile.in b/Makefile.in
index d57c1690f47..7ee41a5bdd5 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -236,6 +236,11 @@ gamedir=@gamedir@
# ==================== Utility Programs for the Build ====================
# Allow the user to specify the install program.
+# Note that if the system does not provide a suitable install,
+# configure will use build-aux/install-sh. Annoyingly, it does
+# not use an absolute path. So we must take care to always run
+# INSTALL-type commands from the top-level directory.
+# This explains (I think) the cd thisdir seen in several install rules.
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_DATA = @INSTALL_DATA@
@@ -621,7 +626,8 @@ install-arch-indep: mkdir info install-etc
for elt in $(INFO_FILES); do \
test "$(HAVE_MAKEINFO)" = "no" && test ! -f $$elt && continue; \
for f in `ls $$elt $$elt-[1-9] $$elt-[1-9][0-9] 2>/dev/null`; do \
- ${INSTALL_DATA} $$f $(DESTDIR)${infodir}/$$f; \
+ (cd $${thisdir}; \
+ ${INSTALL_DATA} ${srcdir}/info/$$f $(DESTDIR)${infodir}/$$f); \
chmod a+r $(DESTDIR)${infodir}/$$f; \
if [ -n "${GZIP_INFO}" ] && [ -n "${GZIP_PROG}" ]; then \
rm -f $(DESTDIR)${infodir}/$$f.gz; \
@@ -724,9 +730,11 @@ uninstall:
fi ; \
done
-rm -rf $(DESTDIR)${libexecdir}/emacs/${version}
+ thisdir=`/bin/pwd`; \
(cd $(DESTDIR)${infodir} && \
for elt in $(INFO_FILES); do \
- $(INSTALL_INFO) --remove --info-dir=. $$elt; \
+ (cd $${thisdir}; \
+ $(INSTALL_INFO) --remove --info-dir=$(DESTDIR)${infodir} $(DESTDIR)${infodir}/$$elt); \
if [ -n "${GZIP_INFO}" ] && [ -n "${GZIP_PROG}" ]; then \
ext=.gz; else ext=; fi; \
for f in `ls $$elt$$ext $$elt-[1-9]$$ext $$elt-[1-9][0-9]$$ext 2>/dev/null`; do \