Skip to content

Commit

Permalink
straight--build-autoloads: Ensure output symlink isn't resolved (#701)
Browse files Browse the repository at this point in the history
In Emacs 28.1, when find-file-visit-truename, a user option, is
non-nil, make-directory-autoloads resolves symlinks in its second
argument (as it uses find-file-noselect under the hood) but not in its
first. This results in relative paths that are invalid when loaded.

See #701, #944, and upstream bug report
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=52292.
  • Loading branch information
kisaragi-hiu committed Jun 15, 2022
1 parent 5fb04bc commit 2458092
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions straight.el
Original file line number Diff line number Diff line change
Expand Up @@ -5136,6 +5136,13 @@ modifies the build folder, not the original repository."
;; Apparently fixes a bug in Emacs 27, see
;; <https://github.com/radian-software/straight.el/issues/434>.
(debug-on-error nil)
;; In Emacs 28.1, if this is non-nil,
;; `make-directory-autoloads' resolves symlinks in its
;; second argument but not the first, and files cannot
;; be loaded correctly. Unfortunately this bug crept
;; into the release. See
;; <https://github.com/raxod502/straight.el/issues/701>
(find-file-visit-truename nil)
;; Non-nil interferes with autoload generation in Emacs < 29, see
;; <https://github.com/radian-software/straight.el/issues/904>.
(left-margin 0))
Expand Down

0 comments on commit 2458092

Please sign in to comment.