]> code.delx.au - gnu-emacs/blobdiff - lisp/Makefile.in
Merge from origin/emacs-24
[gnu-emacs] / lisp / Makefile.in
index 84d92c21e7b010be189727c0dddd9481fcbe2876..22d5ddcf12f331b9dc6c8d3057bdc313919e9347 100644 (file)
@@ -1,6 +1,6 @@
 ### @configure_input@
 
-# Copyright (C) 2000-2014 Free Software Foundation, Inc.
+# Copyright (C) 2000-2015 Free Software Foundation, Inc.
 
 # This file is part of GNU Emacs.
 
@@ -28,13 +28,26 @@ VPATH = $(srcdir)
 # limitation.
 XARGS_LIMIT = @XARGS_LIMIT@
 
+# 'make' verbosity.
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+
+AM_V_ELC = $(am__v_ELC_@AM_V@)
+am__v_ELC_ = $(am__v_ELC_@AM_DEFAULT_V@)
+am__v_ELC_0 = @echo "  ELC     " $@;
+am__v_ELC_1 =
+
+AM_V_GEN = $(am__v_GEN_@AM_V@)
+am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 =
+
 # You can specify a different executable on the make command line,
 # e.g. "make EMACS=../src/emacs ...".
 
 # We never change directory before running Emacs, so a relative file
 # name is fine, and makes life easier.  If we need to change
 # directory, we can use emacs --chdir.
-EMACS = ../src/emacs
+EMACS = ../src/emacs${EXEEXT}
 
 # Command line flags for Emacs.
 
@@ -137,7 +150,8 @@ setwins_for_subdirs=for file in `find ${srcdir} -type d -print`; do \
 # we add them here to make sure they get built.
 all: compile-main $(lisp)/cus-load.el $(lisp)/finder-inf.el
 
-.PHONY: all custom-deps finder-data autoloads update-subdirs
+PHONY_EXTRAS =
+.PHONY: all custom-deps finder-data autoloads update-subdirs $(PHONY_EXTRAS)
 
 # custom-deps and finder-data both used to scan _all_ the *.el files.
 # This could lead to problems in parallel builds if automatically
@@ -153,19 +167,20 @@ all: compile-main $(lisp)/cus-load.el $(lisp)/finder-inf.el
 # Nowadays these commands don't scan automatically generated files,
 # since they will never contain any useful information
 # (see finder-no-scan-regexp and custom-dependencies-no-scan-regexp).
-$(lisp)/cus-load.el:
-       $(MAKE) custom-deps
 custom-deps:
-       $(setwins_almost); \
+       $(AM_V_at)$(MAKE) PHONY_EXTRAS=$(lisp)/cus-load.el $(lisp)/cus-load.el
+$(lisp)/cus-load.el:
+       $(AM_V_GEN)$(setwins_almost); \
        echo Directories: $$wins; \
        $(emacs) -l cus-dep \
          --eval '(setq generated-custom-dependencies-file (unmsys--file-name "$(srcdir)/cus-load.el"))' \
          -f custom-make-dependencies $$wins
 
-$(lisp)/finder-inf.el:
-       $(MAKE) finder-data
 finder-data:
-       $(setwins_finder); \
+       $(AM_V_at)$(MAKE) PHONY_EXTRAS=$(lisp)/finder-inf.el \
+         $(lisp)/finder-inf.el
+$(lisp)/finder-inf.el:
+       $(AM_V_GEN)$(setwins_finder); \
        echo Directories: $$wins; \
        $(emacs) -l finder \
          --eval '(setq generated-finder-keywords-file (unmsys--file-name "$(srcdir)/finder-inf.el"))' \
@@ -177,21 +192,22 @@ finder-data:
 # Note that we set no-update-autoloads in _generated_ leim files.
 # If you want to allow autoloads in such files, remove that,
 # and make this depend on leim.
-autoloads: $(LOADDEFS)
-       $(setwins_almost); \
+autoloads .PHONY: $(lisp)/loaddefs.el
+$(lisp)/loaddefs.el: $(LOADDEFS)
+       $(AM_V_GEN)$(setwins_almost); \
        echo Directories: $$wins; \
        $(emacs) -l autoload \
            --eval '(setq autoload-ensure-writable t)' \
            --eval '(setq autoload-builtin-package-versions t)' \
-           --eval '(setq generated-autoload-file (expand-file-name (unmsys--file-name "$(srcdir)/loaddefs.el")))' \
+           --eval '(setq generated-autoload-file (expand-file-name (unmsys--file-name "$@")))' \
            -f batch-update-autoloads $$wins
 
 # This is required by the bootstrap-emacs target in ../src/Makefile, so
 # we know that if we have an emacs executable, we also have a subdirs.el.
 $(lisp)/subdirs.el:
-       $(MAKE) update-subdirs
+       $(AM_V_GEN)$(MAKE) update-subdirs
 update-subdirs:
-       $(setwins_for_subdirs); \
+       $(AM_V_at)$(setwins_for_subdirs); \
        for file in $$wins; do \
           $(srcdir)/../build-aux/update-subdirs $$file; \
        done;
@@ -249,12 +265,10 @@ TAGS: $(lisptagsfiles1) $(lisptagsfiles2) $(lisptagsfiles3) $(lisptagsfiles4)
 # src/Makefile.in to rebuild a particular Lisp file, no questions asked.
 # Use byte-compile-refresh-preloaded to try and work around some of
 # the most common problems of not bootstrapping from a clean state.
-.PHONY: compile-onefile
-compile-onefile:
-       @echo Compiling $(THEFILE)
-       @# Use byte-compile-refresh-preloaded to try and work around some of
-       @# the most common bootstrapping problems.
-       @$(emacs) $(BYTE_COMPILE_FLAGS) \
+THEFILE = no-such-file
+.PHONY: $(THEFILE)c
+$(THEFILE)c:
+       $(AM_V_ELC)$(emacs) $(BYTE_COMPILE_FLAGS) \
                -l bytecomp -f byte-compile-refresh-preloaded \
                -f batch-byte-compile $(THEFILE)
 
@@ -270,12 +284,7 @@ compile-onefile:
 # An old-fashioned suffix rule, which, according to the GNU Make manual,
 # cannot have prerequisites.
 .el.elc:
-       @echo Compiling $<
-       @# The BIG_STACK_OPTS are only needed to byte-compile the byte-compiler
-       @# files, which is normally done in compile-first, but may also be
-       @# recompiled via this rule.
-       @$(emacs) $(BYTE_COMPILE_FLAGS) \
-               -f batch-byte-compile $<
+       $(AM_V_ELC)$(emacs) $(BYTE_COMPILE_FLAGS) -f batch-byte-compile $<
 
 .PHONY: compile-first compile-main compile compile-always
 
@@ -315,7 +324,7 @@ compile-clean:
        @cd $(lisp) && $(setwins); \
        elcs=`echo "$$wins " | sed -e 's|/\./|/|g' -e 's|/\. | |g' -e 's| |/*.elc |g'`; \
        for el in `echo $$elcs | sed -e 's/\.elc/\.el/g'`; do \
-         if test -f "$$el" -o \! -f "$${el}c"; then :; else \
+         if test -f "$$el" || test ! -f "$${el}c"; then :; else \
            echo rm "$${el}c"; \
            rm "$${el}c"; \
          fi \
@@ -325,13 +334,8 @@ compile-clean:
 leim:
        $(MAKE) -C ../leim all EMACS="$(EMACS)"
 
-# FIXME.  Yuck.
 semantic:
-       case ${EMACS} in \
-         .*) EMACS="../${EMACS}" ;; \
-          *) EMACS="${EMACS}" ;; \
-       esac; \
-       $(MAKE) -C ../admin/grammars all EMACS="$${EMACS}"
+       $(MAKE) -C ../admin/grammars all EMACS="$(EMACS:.%=../.%)"
 
 # Compile all Lisp files, but don't recompile those that are up to
 # date.  Some .el files don't get compiled because they set the
@@ -401,7 +405,7 @@ MH_E_SRC = $(MH_E_DIR)/mh-acros.el $(MH_E_DIR)/mh-alias.el    \
 .PHONY: mh-autoloads
 mh-autoloads: $(MH_E_DIR)/mh-loaddefs.el
 $(MH_E_DIR)/mh-loaddefs.el: $(MH_E_SRC)
-       $(emacs) -l autoload \
+       $(AM_V_GEN)$(emacs) -l autoload \
           --eval "(setq generate-autoload-cookie \";;;###mh-autoload\")" \
           --eval "(setq generated-autoload-file (expand-file-name (unmsys--file-name \"$@\")))" \
           -f batch-update-autoloads $(MH_E_DIR)
@@ -418,7 +422,7 @@ TRAMP_SRC = $(TRAMP_DIR)/tramp.el    $(TRAMP_DIR)/tramp-adb.el      \
        $(TRAMP_DIR)/tramp-uu.el     $(TRAMP_DIR)/trampver.el
 
 $(TRAMP_DIR)/tramp-loaddefs.el: $(TRAMP_SRC)
-       $(emacs) -l autoload \
+       $(AM_V_GEN)$(emacs) -l autoload \
           --eval "(setq generate-autoload-cookie \";;;###tramp-autoload\")" \
           --eval "(setq generated-autoload-file (expand-file-name (unmsys--file-name \"$@\")))" \
           -f batch-update-autoloads $(TRAMP_DIR)
@@ -439,19 +443,19 @@ CAL_SRC = $(CAL_DIR)/cal-bahai.el $(CAL_DIR)/cal-china.el  \
        $(CAL_DIR)/solar.el
 
 $(CAL_DIR)/cal-loaddefs.el: $(CAL_SRC)
-       $(emacs) -l autoload \
+       $(AM_V_GEN)$(emacs) -l autoload \
           --eval "(setq generate-autoload-cookie \";;;###cal-autoload\")" \
           --eval "(setq generated-autoload-file (expand-file-name (unmsys--file-name \"$@\")))" \
           -f batch-update-autoloads $(CAL_DIR)
 
 $(CAL_DIR)/diary-loaddefs.el: $(CAL_SRC) $(CAL_DIR)/cal-loaddefs.el
-       $(emacs) -l autoload \
+       $(AM_V_GEN)$(emacs) -l autoload \
           --eval "(setq generate-autoload-cookie \";;;###diary-autoload\")" \
           --eval "(setq generated-autoload-file (expand-file-name (unmsys--file-name \"$@\")))" \
           -f batch-update-autoloads $(CAL_DIR)
 
 $(CAL_DIR)/hol-loaddefs.el: $(CAL_SRC) $(CAL_DIR)/diary-loaddefs.el
-       $(emacs) -l autoload \
+       $(AM_V_GEN)$(emacs) -l autoload \
           --eval "(setq generate-autoload-cookie \";;;###holiday-autoload\")" \
           --eval "(setq generated-autoload-file (expand-file-name (unmsys--file-name \"$@\")))" \
           -f batch-update-autoloads $(CAL_DIR)
@@ -472,6 +476,11 @@ maintainer-clean: distclean bootstrap-clean
 check-declare:
        $(emacs) -l check-declare --eval '(check-declare-directory "$(lisp)")'
 
+check-defun-dups:
+       sed -n -e '/^(defun /s/\(.\)(.*/\1/p' \
+               $$(find . -name '*.el' -print | grep -v 'loaddefs\.el') \
+           | sort | uniq -d
+
 # Dependencies
 
 ## None of the following matters for bootstrap, which is the only way