summaryrefslogtreecommitdiff
path: root/lisp/Makefile.in
diff options
context:
space:
mode:
authorLars Ingebrigtsen <larsi@gnus.org>2021-12-03 22:21:41 +0100
committerLars Ingebrigtsen <larsi@gnus.org>2021-12-03 22:22:31 +0100
commit352c737dcef4171f71980b432cc86df6511d8643 (patch)
tree120ca3068475210ebe7c1cb9270dfe36f91cc502 /lisp/Makefile.in
parent1e2bc1bbf47782df7f9b8051f33904432c55e6e4 (diff)
downloademacs-352c737dcef4171f71980b432cc86df6511d8643.tar.gz
Ensure that MAIN_FIRST have finished compilation before doing the rest
* lisp/Makefile.in (main-first): Ensure that we're done with the main bits before starting on the rest. (GREP_OPTIONS): Depend on main-first. (MAIN_FIRST): Compile cconv.el before c-by.el (bug#8764).
Diffstat (limited to 'lisp/Makefile.in')
-rw-r--r--lisp/Makefile.in18
1 files changed, 15 insertions, 3 deletions
diff --git a/lisp/Makefile.in b/lisp/Makefile.in
index 4380a3bdb6e..353c9e652c6 100644
--- a/lisp/Makefile.in
+++ b/lisp/Makefile.in
@@ -98,7 +98,7 @@ COMPILE_FIRST += $(lisp)/emacs-lisp/autoload.elc
# Files to compile early in compile-main. Works around bug#25556.
MAIN_FIRST = ./emacs-lisp/eieio.el ./emacs-lisp/eieio-base.el \
- ./cedet/semantic/db.el
+ ./cedet/semantic/db.el ./emacs-lisp/cconv.el
# Prevent any settings in the user environment causing problems.
unexport EMACSDATA EMACSDOC EMACSPATH
@@ -338,10 +338,10 @@ endif
# Compile all the Elisp files that need it. Beware: it approximates
# 'no-byte-compile', so watch out for false-positives!
-compile-main: gen-lisp compile-clean
+compile-main: gen-lisp compile-clean main-first
@(cd $(lisp) && \
els=`echo "${SUBDIRS_REL} " | sed -e 's|/\./|/|g' -e 's|/\. | |g' -e 's| |/*.el |g'`; \
- for el in ${MAIN_FIRST} $$els; do \
+ for el in $$els; do \
test -f $$el || continue; \
test ! -f $${el}c && \
GREP_OPTIONS= grep '^;.*[^a-zA-Z]no-byte-compile: *t' $$el > /dev/null && \
@@ -354,6 +354,18 @@ compile-main: gen-lisp compile-clean
TARGETS="$$chunk"; \
done
+# Compile some important files first.
+main-first:
+ @(cd $(lisp) && \
+ for el in ${MAIN_FIRST}; do \
+ echo "$${el}c"; \
+ done | xargs $(XARGS_LIMIT) echo) | \
+ while read chunk; do \
+ $(MAKE) compile-targets \
+ NATIVE_DISABLED=$(NATIVE_SKIP_NONDUMP) \
+ TARGETS="$$chunk"; \
+ done
+
.PHONY: compile-clean
# Erase left-over .elc files that do not have a corresponding .el file.
compile-clean: