Mercurial > emacs
comparison lisp/emacs-lisp/autoload.el @ 105501:e3e540de3898
(batch-update-autoloads): Rather than having the list of preloaded
files passed on the command-line, get it from src/Makefile.
author | Glenn Morris <rgm@gnu.org> |
---|---|
date | Wed, 07 Oct 2009 07:18:53 +0000 |
parents | fe4228529c23 |
children | a4b36898ee9a |
comparison
equal
deleted
inserted
replaced
105500:f4a201cb497c | 105501:e3e540de3898 |
---|---|
681 | 681 |
682 ;;;###autoload | 682 ;;;###autoload |
683 (defun batch-update-autoloads () | 683 (defun batch-update-autoloads () |
684 "Update loaddefs.el autoloads in batch mode. | 684 "Update loaddefs.el autoloads in batch mode. |
685 Calls `update-directory-autoloads' on the command line arguments." | 685 Calls `update-directory-autoloads' on the command line arguments." |
686 ;; For use during the Emacs build process only. We do the file-name | 686 ;; For use during the Emacs build process only. |
687 ;; expansion here rather than in lisp/Makefile in order to keep the | 687 (unless autoload-excludes |
688 ;; shell command line short. (Long lines are an issue on some systems.) | 688 (let* ((ldir (file-name-directory generated-autoload-file)) |
689 (if (stringp autoload-excludes) | 689 (mfile (expand-file-name "../src/Makefile" ldir)) |
690 (setq autoload-excludes | 690 lim) |
691 (mapcar | 691 (when (file-readable-p mfile) |
692 (lambda (file) | 692 (with-temp-buffer |
693 (concat | 693 (insert-file-contents mfile) |
694 (expand-file-name (file-name-sans-extension file) | 694 (when (re-search-forward "^lisp= ") |
695 (file-name-directory generated-autoload-file)) | 695 (setq lim (line-end-position)) |
696 ".el")) | 696 (while (re-search-forward "\\${lispsource}\\([^ ]*\\)\\.elc?" lim t) |
697 (split-string autoload-excludes)))) | 697 (push (concat (expand-file-name (match-string 1) ldir) ".el") |
698 autoload-excludes))))))) | |
698 (let ((args command-line-args-left)) | 699 (let ((args command-line-args-left)) |
699 (setq command-line-args-left nil) | 700 (setq command-line-args-left nil) |
700 (apply 'update-directory-autoloads args))) | 701 (apply 'update-directory-autoloads args))) |
701 | 702 |
702 (provide 'autoload) | 703 (provide 'autoload) |