]> code.delx.au - gnu-emacs/blobdiff - Makefile.in
Comments
[gnu-emacs] / Makefile.in
index f11a8b3ed060be4838a8b37f1e476b5ba0e7e403..ec74a2ec8a940e0e00eed5e6cb39fa25a73eb07e 100644 (file)
@@ -511,6 +511,14 @@ set_installuser=for installuser in $${LOGNAME} $${USERNAME} $${USER} \
 ## Is it really Emacs's job to create those directories?
 ## Should we also be ensuring they contain subdirs.el files?
 ## It would be easy to do, just use write_subdir.
+
+## Note that we use tar instead of plain old cp -R/-r because the latter
+## is apparently not portable (even in 2012!).
+## http://lists.gnu.org/archive/html/emacs-devel/2012-05/msg00278.html
+## I have no idea which platforms Emacs supports where cp -R does not
+## work correctly, and therefore no idea when tar can be replaced.
+## See also these comments from 2004 about cp -r working fine:
+## http://lists.gnu.org/archive/html/autoconf-patches/2004-11/msg00005.html
 install-arch-indep: install-leim install-info install-man ${INSTALL_ARCH_INDEP_EXTRA}
        umask 022 ; \
          $(MKDIR_P) $(DESTDIR)`echo ${locallisppath} | sed 's,:, $(DESTDIR),g'`
@@ -531,12 +539,16 @@ install-arch-indep: install-leim install-info install-man ${INSTALL_ARCH_INDEP_E
               tar -xvf - && cat > /dev/null) || exit 1; \
          [ "$${dir}" != "${srcdir}/etc" ] || rm -f $${dest}/DOC* ; \
          for subdir in `find $${dest} -type d -print` ; do \
-           rm -f $${subdir}/.gitignore $${subdir}/.arch-inventory \
-             $${subdir}/.DS_Store  $${subdir}/ChangeLog* \
-             $${subdir}/\#*        $${subdir}/.\#*  \
-             $${subdir}/*~         $${subdir}/*.orig ; \
+           rm -f $${subdir}/.gitignore ; \
+           rm -f $${subdir}/.arch-inventory ; \
+           rm -f $${subdir}/.DS_Store ; \
+           rm -f $${subdir}/\#* ; \
+           rm -f $${subdir}/.\#* ; \
+           rm -f $${subdir}/*~ ; \
+           rm -f $${subdir}/*.orig ; \
+           rm -f $${subdir}/ChangeLog* ; \
            [ "$${dir}" != "${srcdir}/etc" ] && \
-            rm -f $${subdir}/[mM]akefile*[.-]in $${subdir}/[mM]akefile ; \
+             rm -f $${subdir}/[mM]akefile*[.-]in $${subdir}/[mM]akefile ; \
          done ; \
          find $${dest} -exec chown $${installuser} {} ';' ;\
        done
@@ -626,11 +638,11 @@ install-etc:
        cd ${iconsrcdir} || exit 1; umask 022 ; \
        for dir in */*/apps */*/mimetypes; do \
          [ -d $${dir} ] || continue ; \
-         ( cd $${thisdir}; ${MKDIR_P} ${icondir}/$${dir} ) ; \
+         ( cd $${thisdir}; ${MKDIR_P} $(DESTDIR)${icondir}/$${dir} ) ; \
          for icon in $${dir}/*.*; do \
            [ -r $${icon} ] || continue ; \
            ( cd $${thisdir}; \
-             ${INSTALL_DATA} ${iconsrcdir}/$${icon} ${icondir}/$${icon} ) \
+             ${INSTALL_DATA} ${iconsrcdir}/$${icon} $(DESTDIR)${icondir}/$${icon} ) \
            || exit 1; \
          done ; \
        done