GNU bug report logs - #36477
Add Guix System cross-compilation support

Previous Next

Package: guix-patches;

Reported by: Mathieu Othacehe <m.othacehe <at> gmail.com>

Date: Tue, 2 Jul 2019 15:19:02 UTC

Severity: normal

Done: Mathieu Othacehe <m.othacehe <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Mathieu Othacehe <m.othacehe <at> gmail.com>
To: 36477 <at> debbugs.gnu.org
Cc: Mathieu Othacehe <m.othacehe <at> gmail.com>
Subject: [bug#36477] [PATCH v4 13/23] gnu: guile-gcrypt: Fix cross-compilation.
Date: Wed,  2 Oct 2019 11:58:54 +0200
* gnu/packages/gnupg.scm (guile-gcrypt) [native-inputs]: Add guile,
[arguments]: add libgcrypt-config to PATH when cross-compiling.
---
 gnu/packages/gnupg.scm | 18 +++++++++++++++++-
 1 file changed, 17 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/gnupg.scm b/gnu/packages/gnupg.scm
index 4acc434093..9ec51d8201 100644
--- a/gnu/packages/gnupg.scm
+++ b/gnu/packages/gnupg.scm
@@ -16,6 +16,7 @@
 ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice <me <at> tobias.gr>
 ;;; Copyright © 2018 Marius Bakke <mbakke <at> fastmail.com>
 ;;; Copyright © 2018 Björn Höfling <bjoern.hoefling <at> bjoernhoefling.de>
+;;; Copyright © 2019 Mathieu Othacehe <m.othacehe <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -479,11 +480,26 @@ gpgpme starting with version 1.7.")
                 "1mhc5m4xygkfj7x18f8apiqpfdn9mrql0am5sk13cf5xn8x1r63z"))
               (file-name (string-append name "-" version "-checkout"))))
     (build-system gnu-build-system)
+    (arguments
+     ;; When cross-compiling, the bash script libgcrypt-config provided by
+     ;; libgcrypt must be accessible during configure phase.
+     `(,@(if (%current-target-system)
+             '(#:phases
+               (modify-phases %standard-phases
+                 (add-before 'configure 'add-libgrypt-config
+                   (lambda _
+                     (setenv "PATH" (string-append
+                                     (assoc-ref %build-inputs "libgcrypt")
+                                     "/bin:"
+                                     (getenv "PATH")))
+                     #t))))
+             '())))
     (native-inputs
      `(("pkg-config" ,pkg-config)
        ("autoconf" ,autoconf)
        ("automake" ,automake)
-       ("texinfo" ,texinfo)))
+       ("texinfo" ,texinfo)
+       ("guile" ,guile-2.2)))
     (inputs
      `(("guile" ,guile-2.2)
        ("libgcrypt" ,libgcrypt)))
-- 
2.23.0





This bug report was last modified 5 years and 270 days ago.

Previous Next


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