summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIhor Radchenko <yantar92@posteo.net>2023-12-24 11:53:39 +0100
committerIhor Radchenko <yantar92@posteo.net>2023-12-24 11:53:39 +0100
commitaf18216738424a214d3440cc000609d88a525590 (patch)
tree0eeebac01f90a3d33dbb564707252d5f8659cc34
parent11c626b52c7954769f53f4e565e760843c4d09bb (diff)
downloadorg-mode-af1821673.tar.gz
org-assert-version: Convert to warning. Add info when building Emacs git
* lisp/org-macs.el (org-assert-version): Do not throw an error - it is preventing Org loading and creating more breakage than the problem it is trying to solve (the version mismatch is problematic occasionally, while the error was thrown every single time). Document what to do when version mismatch is encountered for Org mode built inside Emacs git repository. Link: https://yhetil.org/emacs-devel/83frzsccuy.fsf@gnu.org/T/#t
-rw-r--r--lisp/org-macs.el13
1 files changed, 9 insertions, 4 deletions
diff --git a/lisp/org-macs.el b/lisp/org-macs.el
index 6ed901b..10ef9d0 100644
--- a/lisp/org-macs.el
+++ b/lisp/org-macs.el
@@ -57,7 +57,7 @@ by `package-activate-all').")
;; `org-git-version' check because the generated Org version strings
;; will not match.
`(unless (or org--inhibit-version-check (equal (org-release) ,(org-release)))
- (warn "Org version mismatch. Org loading aborted.
+ (warn "Org version mismatch.
This warning usually appears when a built-in Org version is loaded
prior to the more recent Org version.
@@ -91,10 +91,15 @@ Version mismatch is commonly encountered in the following situations:
early in the config. Ideally, right after the straight.el
bootstrap. Moving `use-package' :straight declaration may not be
sufficient if the corresponding `use-package' statement is
- deferring the loading."
+ deferring the loading.
+
+4. A new Org version is synchronized with Emacs git repository and
+ stale .elc files are still left from the previous build.
+
+ It is recommended to remove .elc files from lisp/org directory and
+ re-compile."
;; Avoid `warn' replacing "'" with "’" (see `format-message').
- "(straight-use-package 'org)")
- (error "Org version mismatch. Make sure that correct `load-path' is set early in init.el")))
+ "(straight-use-package 'org)")))
;; We rely on org-macs when generating Org version. Checking Org
;; version here will interfere with Org build process.