From 1c4bc227523a48dac4bad173cf196cdf8963633d Mon Sep 17 00:00:00 2001 From: Alexandre Duret-Lutz Date: Sun, 1 Feb 2004 12:18:02 +0000 Subject: * automake.in (handle_emacs_lisp): Define $(ELCFILES) as $(am__ELCFILES), and always push it on @all. Do not mention elc-stamp. * lib/am/lisp.am (.el.elc): Rewrite as ... ($(am__ELCFILES)): ... this, and depend on elc-stamp. (elc-stamp): Make sure elc-stamp is older that all .elc files, as explained in the manual entry below. --- lib/am/lisp.am | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'lib/am/lisp.am') diff --git a/lib/am/lisp.am b/lib/am/lisp.am index 392ae6ced..a9232a8a2 100644 --- a/lib/am/lisp.am +++ b/lib/am/lisp.am @@ -27,6 +27,7 @@ endif %?INSTALL% elc-stamp: $(am__ELFILES) @echo 'WARNING: Warnings can be ignored. :-)' + @rm -f elc-temp && touch elc-temp if test "$(EMACS)" != no; then \ ## Make sure "$@" isn't empty initially. set x; \ @@ -40,15 +41,19 @@ elc-stamp: $(am__ELFILES) shift; \ EMACS="$(EMACS)" $(SHELL) $(elisp_comp) "$$@" || exit 1; \ else : ; fi - touch $@ + @mv -f elc-temp $@ -.el.elc: +## Do not use $(ELCFILES) as target, because it may have been emptied +## by the user (to disable byte-compilation), and POSIX does not allow +## an empty target. +$(am__ELCFILES): elc-stamp ## Recover from the removal of $@ @if test ! -f $@; then \ rm -f elc-stamp; \ $(MAKE) $(AM_MAKEFLAGS) elc-stamp; \ else : ; fi + ## ------------ ## ## Installing. ## ## ------------ ## -- cgit v1.2.1