diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2017-03-21 09:59:10 -0700 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2017-03-21 09:59:31 -0700 |
commit | bf8cf95d7d13ebc5d351cc2a8048f6695ab9faca (patch) | |
tree | 1aa66a743bb6b542c2764e4c77979ede678d6881 /src/Makefile.in | |
parent | 14d8b6858a49e97f9b69593df5a8a7886430d43f (diff) | |
download | emacs-bf8cf95d7d13ebc5d351cc2a8048f6695ab9faca.tar.gz |
Streamline dependency-file generation
* configure.ac (AUTODEPEND_PARENTS): New var.
mkdir the dependency directories here, to simplify ‘make’.
Remove dependency files just before outputting Makefiles, so that
they are preserved if ‘configure’ exits early due to some other problem.
* lib/Makefile.in, lwlib/Makefile.in, oldXMenu/Makefile.in:
* src/Makefile.in: Adjust deps strategies to be similar, as follows:
(MKDEPDIR): Remove. All uses removed. This cuts down on the
number of processes spun off by ‘make’.
(clean mostlyclean): Remove $(DEPDIR) contents, not $(DEPDIR) itself.
(distclean): Remove $(DEPDIR) itself.
* lwlib/Makefile.in (all): Move to front, so that depdir includes
do not alter default action.
Diffstat (limited to 'src/Makefile.in')
-rw-r--r-- | src/Makefile.in | 25 |
1 files changed, 7 insertions, 18 deletions
diff --git a/src/Makefile.in b/src/Makefile.in index 60aa6866718..5a3d0bd0445 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -347,15 +347,14 @@ am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = -DEPDIR=deps AUTO_DEPEND = @AUTO_DEPEND@ - +DEPDIR = deps ifeq ($(AUTO_DEPEND),yes) -DEPFLAGS = -MMD -MF ${DEPDIR}/$*.d -MP -MKDEPDIR = ${MKDIR_P} ${DEPDIR} + DEPFLAGS = -MMD -MF $(DEPDIR)/$*.d -MP + -include $(ALLOBJS:%.o=$(DEPDIR)/%.d) else -DEPFLAGS = -MKDEPDIR = : + DEPFLAGS = + include $(srcdir)/deps.mk endif # Flags that might be in WARN_CFLAGS but are not valid for Objective C. @@ -383,10 +382,8 @@ ALL_OBJC_CFLAGS = $(EMACS_CFLAGS) \ .SUFFIXES: .m .c.o: - @$(MKDEPDIR) $(AM_V_CC)$(CC) -c $(CPPFLAGS) $(ALL_CFLAGS) $(PROFILING_CFLAGS) $< .m.o: - @$(MKDEPDIR) $(AM_V_CC)$(CC) -c $(CPPFLAGS) $(ALL_OBJC_CFLAGS) $(PROFILING_CFLAGS) $< ## lastfile must follow all files whose initialized data areas should @@ -650,8 +647,7 @@ mostlyclean: rm -f globals.h gl-stamp rm -f *.res *.tmp clean: mostlyclean - rm -f emacs-*.*.*$(EXEEXT) emacs$(EXEEXT) - -rm -rf $(DEPDIR) + rm -f emacs-*.*.*$(EXEEXT) emacs$(EXEEXT) $(DEPDIR)/* ## bootstrap-clean is used to clean up just before a bootstrap. ## It should remove all files generated during a compilation/bootstrap, @@ -666,6 +662,7 @@ bootstrap-clean: clean distclean: bootstrap-clean rm -f Makefile lisp.mk + rm -fr $(DEPDIR) maintainer-clean: distclean rm -f TAGS @@ -755,11 +752,3 @@ else endif @: Compile some files earlier to speed up further compilation. $(MAKE) -C ../lisp compile-first EMACS="$(bootstrap_exe)" - -ifeq ($(AUTO_DEPEND),yes) --include $(ALLOBJS:%.o=${DEPDIR}/%.d) -else -include $(srcdir)/deps.mk -endif - -### Makefile.in ends here |