summary refs log tree commit diff
path: root/gnu/packages/emacs.scm
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/packages/emacs.scm')
-rw-r--r--gnu/packages/emacs.scm9
1 files changed, 7 insertions, 2 deletions
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 95859b8a88..eba7f88551 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -143,6 +143,11 @@
                    (display
                     (string-append "(when (require 'guix-emacs nil t)\n"
                                    "  (guix-emacs-autoload-packages))\n"))))
+               ;; Remove the extraneous subdirs.el file, as it causes Emacs to
+               ;; add recursively all the the sub-directories of a profile's
+               ;; share/emacs/site-lisp union when added to EMACSLOADPATH,
+               ;; which leads to conflicts.
+               (delete-file (string-append lisp-dir "/subdirs.el"))
                #t))))))
     (inputs
      `(("gnutls" ,gnutls)
@@ -187,8 +192,8 @@
      (list (search-path-specification
             (variable "EMACSLOADPATH")
             ;; The versioned entry is for the Emacs' builtin libraries.
-            (files (list (string-append "share/emacs/" version "/lisp")
-                         "share/emacs/site-lisp")))
+            (files (list "share/emacs/site-lisp"
+                         (string-append "share/emacs/" version "/lisp"))))
            (search-path-specification
             (variable "INFOPATH")
             (files '("share/info")))))