From e5fcdb5e920e0e07df77ff28e7a5dcd2d4f193fa Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Sun, 8 Apr 2012 23:58:41 -0700 Subject: [PATCH] Look for leim-list.el files in fewer places at startup * lisp/startup.el (normal-top-level): Don't look for leim-list.el in places where it will not be found. Fixes: debbugs:910 --- etc/NEWS | 5 +++++ lisp/ChangeLog | 3 +++ lisp/startup.el | 13 ++++++++++--- 3 files changed, 18 insertions(+), 3 deletions(-) diff --git a/etc/NEWS b/etc/NEWS index ae6ba8d36b7..16357f3cfd3 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -24,6 +24,11 @@ so we will look at it and add it to the manual. * Installation Changes in Emacs 24.2 * Startup Changes in Emacs 24.2 + +** Emacs no longer searches for `leim-list.el' files beneath the standard +lisp/ directory. There should not be any there anyway. If you have +been adding them there, put them somewhere else, eg site-lisp. + * Changes in Emacs 24.2 diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ca2812b4996..ed4470b998a 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2012-04-09 Glenn Morris + * startup.el (normal-top-level): Don't look for leim-list.el + in places where it will not be found. (Bug#910) + * international/mule-cmds.el (set-default-coding-systems): * files.el (normal-mode): Remove guarded calls to ucs-set-table-for-input. (Bug#9821) diff --git a/lisp/startup.el b/lisp/startup.el index 37e4f550dcd..518b53ccdf1 100644 --- a/lisp/startup.el +++ b/lisp/startup.el @@ -490,13 +490,20 @@ It is the default value of the variable `top-level'." ;; of that dir into load-path, ;; Look for a leim-list.el file too. Loading it will register ;; available input methods. - (let ((tail load-path) dir) + (let ((tail load-path) + (lispdir (expand-file-name "../lisp" data-directory)) + ;; For out-of-tree builds, leim-list is generated in the build dir. +;;; (leimdir (expand-file-name "../leim" doc-directory)) + dir) (while tail (setq dir (car tail)) (let ((default-directory dir)) (load (expand-file-name "subdirs.el") t t t)) - (let ((default-directory dir)) - (load (expand-file-name "leim-list.el") t t t)) + ;; Do not scan standard directories that won't contain a leim-list.el. + ;; http://lists.gnu.org/archive/html/emacs-devel/2009-10/msg00502.html + (or (string-match (concat "\\`" lispdir) dir) + (let ((default-directory dir)) + (load (expand-file-name "leim-list.el") t t t))) ;; We don't use a dolist loop and we put this "setq-cdr" command at ;; the end, because the subdirs.el files may add elements to the end ;; of load-path and we want to take it into account. -- 2.39.2