]> code.delx.au - gnu-emacs/blobdiff - lisp/Makefile.in
* lisp/emacs-lisp/autoload.el (autoload-generate-file-autoloads):
[gnu-emacs] / lisp / Makefile.in
index 4fba1053dfad61c2668a2fd9cb6299233664a646..ffd31efa1d7691228028bc5b45273b328706e3e8 100644 (file)
 SHELL = @SHELL@
 
 srcdir = @srcdir@
+abs_srcdir = @abs_srcdir@
 top_srcdir = @top_srcdir@
 abs_top_builddir = @abs_top_builddir@
+abs_lisp = $(abs_srcdir)
 lisp = $(srcdir)
 VPATH = $(srcdir)
 
@@ -74,7 +76,8 @@ AUTOGENEL = loaddefs.el \
        eshell/esh-groups.el \
        cedet/semantic/loaddefs.el \
        cedet/ede/loaddefs.el \
-       cedet/srecode/loaddefs.el
+       cedet/srecode/loaddefs.el \
+       org/org-loaddefs.el
 
 # Versioned files that are the value of someone's `generated-autoload-file'.
 # Note that update_loaddefs parses this.
@@ -112,7 +115,7 @@ COMPILE_FIRST = \
 
 # The actual Emacs command run in the targets below.
 
-emacs = EMACSLOADPATH=$(lisp) LC_ALL=C $(EMACS) $(EMACSOPT)
+emacs = EMACSLOADPATH="$(abs_lisp)" LC_ALL=C "$(EMACS)" $(EMACSOPT)
 
 # Common command to find subdirectories
 setwins=subdirs=`find . -type d -print`; \
@@ -163,25 +166,25 @@ doit:
 $(lisp)/cus-load.el:
        $(MAKE) $(MFLAGS) custom-deps
 custom-deps: doit
-       cd $(lisp); $(setwins_almost); \
+       cd $(lisp) && $(setwins_almost); \
        echo Directories: $$wins; \
-       $(emacs) -l cus-dep --eval '(setq generated-custom-dependencies-file (unmsys--file-name "$(lisp)/cus-load.el"))' -f custom-make-dependencies $$wins
+       $(emacs) -l cus-dep --eval '(setq generated-custom-dependencies-file (unmsys--file-name "$(abs_lisp)/cus-load.el"))' -f custom-make-dependencies $$wins
 
 $(lisp)/finder-inf.el:
        $(MAKE) $(MFLAGS) finder-data
 finder-data: doit
-       cd $(lisp); $(setwins_almost); \
+       cd $(lisp) && $(setwins_almost); \
        echo Directories: $$wins; \
-       $(emacs) -l finder --eval '(setq generated-finder-keywords-file (unmsys--file-name "$(lisp)/finder-inf.el"))' -f finder-compile-keywords-make-dist $$wins
+       $(emacs) -l finder --eval '(setq generated-finder-keywords-file (unmsys--file-name "$(abs_lisp)/finder-inf.el"))' -f finder-compile-keywords-make-dist $$wins
 
 # The chmod +w is to handle env var CVSREAD=1.
 autoloads: $(LOADDEFS) doit
        cd $(lisp) && chmod +w $(AUTOGEN_VCS)
-       cd $(lisp); $(setwins_almost); \
+       cd $(lisp) && $(setwins_almost); \
        echo Directories: $$wins; \
        $(emacs) -l autoload \
            --eval '(setq autoload-builtin-package-versions t)' \
-           --eval '(setq generated-autoload-file (unmsys--file-name "$(lisp)/loaddefs.el"))' \
+           --eval '(setq generated-autoload-file (unmsys--file-name "$(abs_lisp)/loaddefs.el"))' \
            -f batch-update-autoloads $$wins
 
 # This is required by the bootstrap-emacs target in ../src/Makefile, so
@@ -189,9 +192,9 @@ autoloads: $(LOADDEFS) doit
 $(lisp)/subdirs.el:
        $(MAKE) $(MFLAGS) update-subdirs
 update-subdirs: doit
-       cd $(lisp); $(setwins_for_subdirs); \
+       cd $(lisp) && $(setwins_for_subdirs); \
        for file in $$wins; do \
-          $(top_srcdir)/build-aux/update-subdirs $$file; \
+          ../build-aux/update-subdirs $$file; \
        done;
 
 .PHONY: updates bzr-update update-authors
@@ -263,7 +266,7 @@ compile-first: $(COMPILE_FIRST)
 # In `compile-main' we could directly do
 #    ... | xargs $(MAKE) $(MFLAGS) EMACS="$(EMACS)"
 # and it works, but it generates a lot of messages like
-#    make[2]: « gnus/gnus-mlspl.elc » is up to date.
+#    make[2]: gnus/gnus-mlspl.elc is up to date.
 # so instead, we use "xargs echo" to split the list of file into manageable
 # chunks and then use an intermediate `compile-targets' target so the
 # actual targets (the .elc files) are not mentioned as targets on the
@@ -277,7 +280,7 @@ compile-targets: $(TARGETS)
 # Compile all the Elisp files that need it.  Beware: it approximates
 # `no-byte-compile', so watch out for false-positives!
 compile-main: compile-clean
-       @(cd $(lisp); $(setwins); \
+       @(cd $(lisp) && $(setwins); \
        els=`echo "$$wins " | sed -e 's|/\./|/|g' -e 's|/\. | |g' -e 's| |/*.el |g'`; \
        for el in $$els; do \
          test -f $$el || continue; \
@@ -291,7 +294,7 @@ compile-main: compile-clean
 .PHONY: compile-clean
 # Erase left-over .elc files that do not have a corresponding .el file.
 compile-clean:
-       @cd $(lisp); $(setwins); \
+       @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 \
@@ -307,22 +310,16 @@ compile-clean:
 # Explicitly pass EMACS (sometimes ../src/bootstrap-emacs) to those
 # sub-makes that run rules that use it, for the sake of some non-GNU makes.
 compile: $(LOADDEFS) autoloads compile-first
-       $(MAKE) $(MFLAGS) compile-main EMACS=$(EMACS)
+       $(MAKE) $(MFLAGS) compile-main EMACS="$(EMACS)"
 
 # Compile all Lisp files.  This is like `compile' but compiles files
 # unconditionally.  Some files don't actually get compiled because they
 # set the local variable no-byte-compile.
 compile-always: doit
-       cd $(lisp); rm -f *.elc */*.elc */*/*.elc */*/*/*.elc
-       $(MAKE) $(MFLAGS) compile EMACS=$(EMACS)
+       cd $(lisp) && rm -f *.elc */*.elc */*/*.elc */*/*/*.elc
+       $(MAKE) $(MFLAGS) compile EMACS="$(EMACS)"
 
-.PHONY: compile-calc backup-compiled-files compile-after-backup
-
-compile-calc:
-       for el in $(lisp)/calc/*.el; do \
-         echo Compiling $$el; \
-         $(emacs) $(BYTE_COMPILE_FLAGS) -f batch-byte-compile $$el || exit 1;\
-       done
+.PHONY: backup-compiled-files compile-after-backup
 
 # Backup compiled Lisp files in elc.tar.gz.  If that file already
 # exists, make a backup of it.
@@ -378,7 +375,7 @@ mh-autoloads: $(MH_E_DIR)/mh-loaddefs.el
 $(MH_E_DIR)/mh-loaddefs.el: $(MH_E_SRC)
        $(emacs) -l autoload \
           --eval "(setq generate-autoload-cookie \";;;###mh-autoload\")" \
-          --eval "(setq generated-autoload-file (unmsys--file-name \"$@\"))" \
+          --eval "(setq generated-autoload-file (expand-file-name (unmsys--file-name \"$@\")))" \
           --eval "(setq make-backup-files nil)" \
           -f batch-update-autoloads $(MH_E_DIR)
 
@@ -396,7 +393,7 @@ TRAMP_SRC = $(TRAMP_DIR)/tramp.el    $(TRAMP_DIR)/tramp-adb.el      \
 $(TRAMP_DIR)/tramp-loaddefs.el: $(TRAMP_SRC)
        $(emacs) -l autoload \
           --eval "(setq generate-autoload-cookie \";;;###tramp-autoload\")" \
-          --eval "(setq generated-autoload-file (unmsys--file-name \"$@\"))" \
+          --eval "(setq generated-autoload-file (expand-file-name (unmsys--file-name \"$@\")))" \
           --eval "(setq make-backup-files nil)" \
           -f batch-update-autoloads $(TRAMP_DIR)
 
@@ -418,28 +415,28 @@ CAL_SRC = $(CAL_DIR)/cal-bahai.el $(CAL_DIR)/cal-china.el  \
 $(CAL_DIR)/cal-loaddefs.el: $(CAL_SRC)
        $(emacs) -l autoload \
           --eval "(setq generate-autoload-cookie \";;;###cal-autoload\")" \
-          --eval "(setq generated-autoload-file (unmsys--file-name \"$@\"))" \
+          --eval "(setq generated-autoload-file (expand-file-name (unmsys--file-name \"$@\")))" \
           --eval "(setq make-backup-files nil)" \
           -f batch-update-autoloads $(CAL_DIR)
 
 $(CAL_DIR)/diary-loaddefs.el: $(CAL_SRC)
        $(emacs) -l autoload \
           --eval "(setq generate-autoload-cookie \";;;###diary-autoload\")" \
-          --eval "(setq generated-autoload-file (unmsys--file-name \"$@\"))" \
+          --eval "(setq generated-autoload-file (expand-file-name (unmsys--file-name \"$@\")))" \
           --eval "(setq make-backup-files nil)" \
           -f batch-update-autoloads $(CAL_DIR)
 
 $(CAL_DIR)/hol-loaddefs.el: $(CAL_SRC)
        $(emacs) -l autoload \
           --eval "(setq generate-autoload-cookie \";;;###holiday-autoload\")" \
-          --eval "(setq generated-autoload-file (unmsys--file-name \"$@\"))" \
+          --eval "(setq generated-autoload-file (expand-file-name (unmsys--file-name \"$@\")))" \
           --eval "(setq make-backup-files nil)" \
           -f batch-update-autoloads $(CAL_DIR)
 
 .PHONY: bootstrap-clean distclean maintainer-clean
 
 bootstrap-clean:
-       cd $(lisp); rm -f *.elc */*.elc */*/*.elc */*/*/*.elc $(AUTOGENEL)
+       -cd $(lisp) && rm -f *.elc */*.elc */*/*.elc */*/*/*.elc $(AUTOGENEL)
 
 distclean:
        -rm -f ./Makefile $(lisp)/loaddefs.el~
@@ -449,8 +446,7 @@ maintainer-clean: distclean bootstrap-clean
 .PHONY: check-declare
 
 check-declare:
-       $(emacs) -l $(lisp)/emacs-lisp/check-declare \
-         --eval '(check-declare-directory "$(lisp)")'
+       $(emacs) -l check-declare --eval '(check-declare-directory "$(lisp)")'
 
 # Dependencies