summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2023-05-10 09:59:46 -0700
committerSean Whitton <spwhitton@spwhitton.name>2023-05-10 09:59:57 -0700
commit268480b3de5778c2c946a5ee0397a359511e183a (patch)
treef57337d798d3003770bb03b71a669a08790be9ff
parentf975e07ee99eb5fdee30e981f9738148e11f2a2a (diff)
downloaddotfiles-268480b3de5778c2c946a5ee0397a359511e183a.tar.gz
avoid gdbmacs loading uncompiled Gnus
-rw-r--r--.emacs.d/init.el8
1 files changed, 6 insertions, 2 deletions
diff --git a/.emacs.d/init.el b/.emacs.d/init.el
index 0ad77a61..e7e5a97a 100644
--- a/.emacs.d/init.el
+++ b/.emacs.d/init.el
@@ -58,7 +58,7 @@
(expand-file-name "initlibs/" user-emacs-directory))
t)
-;; gdbmacs loads Gnus out of ~/src/emacs/primary/, if it's there.
+;; gdbmacs loads Gnus out of ~/src/emacs/primary/, if it's there & compiled.
(when (string= (daemonp) "gdbmacs")
(let ((gnus-primary (expand-file-name "~/src/emacs/primary/lisp/gnus/")))
(when (file-directory-p gnus-primary)
@@ -67,7 +67,11 @@
(gnus-lib-cons
(or (member (directory-file-name gnus-lib-dir) load-path)
(member gnus-lib-dir load-path))))
- (rplaca gnus-lib-cons (directory-file-name gnus-primary))))))
+ (cl-loop for f in (directory-files-recursively gnus-primary
+ emacs-lisp-file-regexp)
+ always (file-exists-p (byte-compile-dest-file f))
+ finally (rplaca gnus-lib-cons
+ (directory-file-name gnus-primary)))))))
(require 'cl-lib)
(require 'subr-x)