GNU bug report logs -
#48205
[PATCH] gnu: emacs-org: Make build reproducible
Previous Next
Reported by: Morgan.J.Smith <at> outlook.com
Date: Mon, 3 May 2021 21:11:01 UTC
Severity: normal
Tags: patch
Done: Nicolas Goaziou <mail <at> nicolasgoaziou.fr>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
From: Morgan Smith <Morgan.J.Smith <at> outlook.com>
* gnu/packages/emacs-xyz.scm (emacs-org)[phases]: Remove loaddefs and use
autoloads instead. Copy autoloads into build directory.
---
Thanks for the suggestions! Sorry about the delay. Also sorry about the
comment. It's probably a little too long :/. I need to work on my english and
my ability to be concise.
gnu/packages/emacs-xyz.scm | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)
diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index 1d954ec5bd..180b2709fe 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -11761,6 +11761,27 @@ (define-public emacs-org
(arguments
`(#:phases
(modify-phases %standard-phases
+ ;; Org ships with the file org-loaddefs.el that functions like our
+ ;; autoloads. Something about the interaction between the loaddefs
+ ;; and autoloads makes the build non-deterministic. We should opt for
+ ;; our autoloads system over the loaddefs since the loaddefs are
+ ;; autogenerated for the release tarball. org-loaddefs.el is
+ ;; mentioned by name in the source files so we have to do a blanket
+ ;; regex search and replace.
+ (add-after 'unpack 'use-autoloads
+ (lambda _
+ (delete-file "org-loaddefs.el")
+ (substitute* (find-files "." "\\.el$")
+ (("org-loaddefs.el") "org-autoloads.el"))))
+ ;; We create the autoloads directly in the install folder. During
+ ;; compilation org checks for the autoloads file so we need to copy
+ ;; it to the build directory.
+ (add-after 'make-autoloads 'copy-autoload-to-build-dir
+ (lambda* (#:key outputs #:allow-other-keys)
+ (copy-file (string-append
+ (elpa-directory (assoc-ref outputs "out"))
+ "/org-autoloads.el")
+ "org-autoloads.el")))
(add-after 'install 'install-documentation
(lambda* (#:key outputs #:allow-other-keys)
(let* ((share (string-append (assoc-ref outputs "out") "/share"))
--
2.32.0
This bug report was last modified 3 years and 231 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.