guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

04/08: transformations: tuned-package: Use target on cross-compile.


From: guix-commits
Subject: 04/08: transformations: tuned-package: Use target on cross-compile.
Date: Sun, 17 Sep 2023 09:37:20 -0400 (EDT)

civodul pushed a commit to branch master
in repository guix.

commit 19b617370844ad48eab68e6fc4b9e47665f71710
Author: Jean-Pierre De Jesus DIAZ <jean@foundationdevices.com>
AuthorDate: Wed Jul 26 17:37:29 2023 +0200

    transformations: tuned-package: Use target on cross-compile.
    
    * guix/transformations.scm (tuned-package): Use either bag-target if
      available or bag-system to select the CPU architecture of the package
      that is going to be tuned.  This enables the tuning of cross-compiled
      packages.
    
    Signed-off-by: Ludovic Courtès <ludo@gnu.org>
---
 guix/transformations.scm | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/guix/transformations.scm b/guix/transformations.scm
index ede914456f..9cba6bedab 100644
--- a/guix/transformations.scm
+++ b/guix/transformations.scm
@@ -529,8 +529,9 @@ system that builds code for MICRO-ARCHITECTURE; otherwise 
raise an error."
     ;; leading to an obscure build error, check whether the compiler is known
     ;; to support MICRO-ARCHITECTURE.  If not, bail out.
     (let* ((lowered      (apply lower args))
-           (architecture (match (string-tokenize (bag-system lowered)
-                                                 %not-hyphen)
+           (target (or (bag-target lowered)
+                       (bag-system lowered)))
+           (architecture (match (string-tokenize target %not-hyphen)
                            ((arch _ ...) arch)))
            (compiler     (any (match-lambda
                                 ((label (? package? p) . _)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]