Commit 9d7316f0 authored by Glenn Morris's avatar Glenn Morris

(update-elclist): Hide the warning when it does not apply, make it

milder when it does.
(autogen-clean): New target.
(maintainer-clean): Use autogen-clean.
parent a9bb457b
......@@ -151,20 +151,12 @@ TAGS TAGS-LISP: $(lisptagsfiles1) $(lisptagsfiles2)
.PHONY: update-elclist
## Construct a sed command file that operates on lines between
## ^ELCFILES and the next blank line. Convert spaces between members
## of COMPILE_FIRST to "\|", and escape directory "/". List the .elc
## files, exclude the members of COMPILE_FIRST, convert ^$(lisp) to a
## literal " $(lisp)", add trailing " \\\" to the end of every line
## (the last \ continues the line in sed, the other \\ result in a
## single \ at the end of the replacement text). For the last line,
## just use a single "\", for sed. Finally, run sed using the command
## so constructed and update Makefile.in. chmod +w is for CVSREAD=1.
## Errors in final sed are non-fatal, since they have no effect on
## building Emacs.
## Post-bootstrap, find the list of .elc files, exclude the members
## of COMPILE_FIRST, and use sed to update ELCFILES in Makefile.in.
## Errors in the final sed are non-fatal, since they have no effect on
## building Emacs. chmod +w is for CVSREAD=1.
## "echo" is non-portable with regards to backslashes, eg between zsh
## and bash. Hence the used of sed on line 2 below (the ones on line
## 1 seem to be OK).
## and bash. Hence the use of sed on line 2 below (line 1 seems to be OK).
## http://lists.gnu.org/archive/html/emacs-devel/2008-05/msg01535.html
update-elclist:
echo "/^ELCFILES/,/^$$/c\\" > temp.sed
......@@ -174,8 +166,11 @@ update-elclist:
echo "" >> temp.sed
-sed -f temp.sed $(lisp)/Makefile.in > temp-elcfiles || rm temp-elcfiles
rm temp.sed
chmod +w $(lisp)/Makefile.in
mv -f temp-elcfiles $(lisp)/Makefile.in || echo "Maintainer warning: failed to update Makefile.in"
@test -f temp-elcfiles || echo "Maintainer warning: failed to update Makefile.in. You can ignore this if you are not an Emacs developer."
if test -f temp-elcfiles; then \
chmod +w $(lisp)/Makefile.in; \
mv -f temp-elcfiles $(lisp)/Makefile.in; \
fi
## Explicitly list the .elc files, for the sake of parallel builds.
## http://lists.gnu.org/archive/html/bug-gnu-emacs/2008-05/msg00016.html
......@@ -1403,9 +1398,11 @@ bootstrap-prepare:
$(MAKE) $(MFLAGS) autoloads; \
fi
maintainer-clean: distclean bootstrap-clean
autogen-clean:
cd $(lisp); rm -f $(AUTOGENEL)
maintainer-clean: distclean bootstrap-clean autogen-clean
## NB note that this rules assume only one level of subdirs below lisp/.
## If nested subdirs are added, it's probably time to switch to:
## find $(lisp) -name "*.elc" -exec rm -f '{}' ';'
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment