diff options
author | Sean Whitton <spwhitton@spwhitton.name> | 2022-06-30 17:07:01 -0700 |
---|---|---|
committer | Sean Whitton <spwhitton@spwhitton.name> | 2022-06-30 17:07:01 -0700 |
commit | 8562fa4e2be05eca507733c06cc4fd6b5cbaa973 (patch) | |
tree | ef369c4a029c8bc6413ab098e56cacb06843eae5 /lisp/startup.el | |
parent | 631abb491b6c8955ef27982cf27c004f569ac835 (diff) | |
parent | 85c2f3bc3efd9cdd092a6d4fadca5cc04642a2a5 (diff) | |
download | emacs-8562fa4e2be05eca507733c06cc4fd6b5cbaa973.tar.gz |
Merge remote-tracking branch 'origin/master' into athena/unstable
Diffstat (limited to 'lisp/startup.el')
-rw-r--r-- | lisp/startup.el | 38 |
1 files changed, 7 insertions, 31 deletions
diff --git a/lisp/startup.el b/lisp/startup.el index 279dfa013c3..78288619d3c 100644 --- a/lisp/startup.el +++ b/lisp/startup.el @@ -557,25 +557,12 @@ to `user-emacs-directory'. For best results, call this function in your early-init file, so that the rest of initialization and package loading uses the updated value." - (let ((tmp-dir (and (equal (getenv "HOME") "/nonexistent") - (file-writable-p (expand-file-name - (or temporary-file-directory ""))) - (car native-comp-eln-load-path)))) - (if tmp-dir - (setq native-comp-eln-load-path - (cdr native-comp-eln-load-path))) - ;; Remove the original eln-cache. - (setq native-comp-eln-load-path - (cdr native-comp-eln-load-path)) - ;; Add the new eln-cache. - (push (expand-file-name (file-name-as-directory cache-directory) - user-emacs-directory) - native-comp-eln-load-path) - (when tmp-dir - ;; Recompute tmp-dir, in case user-emacs-directory affects it. - (setq tmp-dir (make-temp-file "emacs-testsuite-" t)) - (add-hook 'kill-emacs-hook (lambda () (delete-directory tmp-dir t))) - (push tmp-dir native-comp-eln-load-path)))) + ;; Remove the original eln-cache. + (setq native-comp-eln-load-path (cdr native-comp-eln-load-path)) + ;; Add the new eln-cache. + (push (expand-file-name (file-name-as-directory cache-directory) + user-emacs-directory) + native-comp-eln-load-path)) (defun startup--update-eln-cache () "Update the user eln-cache directory due to user customizations." @@ -619,18 +606,7 @@ It is the default value of the variable `top-level'." (unless (string= "" path) (push path native-comp-eln-load-path))))) (push (expand-file-name "eln-cache/" user-emacs-directory) - native-comp-eln-load-path) - ;; When $HOME is set to '/nonexistent' means we are running the - ;; testsuite, add a temporary folder in front to produce there - ;; new compilations. - (when (and (equal (getenv "HOME") "/nonexistent") - ;; We may be running in a chroot environment where we - ;; can't write anything. - (file-writable-p (expand-file-name - (or temporary-file-directory "")))) - (let ((tmp-dir (make-temp-file "emacs-testsuite-" t))) - (add-hook 'kill-emacs-hook (lambda () (delete-directory tmp-dir t))) - (push tmp-dir native-comp-eln-load-path)))) + native-comp-eln-load-path)) ;; Look in each dir in load-path for a subdirs.el file. If we ;; find one, load it, which will add the appropriate subdirs of |