GNU bug report logs - #57086
[PATCH 0/6] Add native compilation to Emacs

Previous Next

Package: guix-patches;

Reported by: Liliana Marie Prikler <liliana.prikler <at> gmail.com>

Date: Tue, 9 Aug 2022 18:45:01 UTC

Severity: normal

Tags: patch

Done: Liliana Marie Prikler <liliana.prikler <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


Message #20 received at 57086 <at> debbugs.gnu.org (full text, mbox):

From: Liliana Marie Prikler <liliana.prikler <at> gmail.com>
To: 57086 <at> debbugs.gnu.org
Subject: [PATCH 6/6] build-system: emacs: Use native compilation.
Date: Tue, 9 Aug 2022 20:32:37 +0200
* guix/build/emacs-build-system.scm (build): Use ‘emacs-compile-directory’
rather than ‘emacs-byte-compile-directory’.  Also delete already compiled
files in the working directory prior to compilation.
---
 guix/build/emacs-build-system.scm | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/guix/build/emacs-build-system.scm b/guix/build/emacs-build-system.scm
index 6a6918bfdd..9ecfceccf1 100644
--- a/guix/build/emacs-build-system.scm
+++ b/guix/build/emacs-build-system.scm
@@ -110,11 +110,14 @@ (define* (expand-load-path #:key (prepend-source? #t) #:allow-other-keys)
 
 (define* (build #:key outputs inputs #:allow-other-keys)
   "Compile .el files."
+  ;; Ensure that already compiled files in the working directory don't shadow
+  ;; the build.  Might happen, because check runs first.
+  (for-each delete-file (find-files "." "\\.el[cn]$"))
   (let* ((emacs (search-input-file inputs "/bin/emacs"))
          (out (assoc-ref outputs "out")))
     (setenv "SHELL" "sh")
     (parameterize ((%emacs emacs))
-      (emacs-byte-compile-directory (elpa-directory out)))))
+      (emacs-compile-directory (elpa-directory out)))))
 
 (define* (patch-el-files #:key outputs #:allow-other-keys)
   "Substitute the absolute \"/bin/\" directory with the right location in the
-- 
2.37.0





This bug report was last modified 2 years and 214 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.