From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:306:2d92::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms9.migadu.com with LMTPS id OD3hCK5BwWRnSAEASxT56A (envelope-from ) for ; Wed, 26 Jul 2023 17:54:22 +0200 Received: from aspmx1.migadu.com ([2001:41d0:306:2d92::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id GITdCK5BwWS7EQAA9RJhRA (envelope-from ) for ; Wed, 26 Jul 2023 17:54:22 +0200 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 9F261452C1 for ; Wed, 26 Jul 2023 17:54:21 +0200 (CEST) Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=foundationdevices.com header.s=google header.b=GpSKM78a; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gnu.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1690386861; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=TVgOWdWsXw1xxsq3WDTo/GcgGSoVbMHVqhzrmLCFt0I=; b=uGClMat4D24XuEaXNfnda5y5hub8wFeGcfbUiYoEnyG1KYzZ1+DAC9OYN7uzNJp1DdJ+d0 LtAeobYgzOHantPIqUvvYAuLiW2OqjQ39RQdwGF8Mc4aGdX/mcG1HxXRUVf4UDX+NedFQC LhKTOg7JpbQkZGwxP2p5aPqIzSgQ6qNjUI2RnxWOxoh5EEkjhf5AL3m9TNWDEgnOfGOtBW 8zGLcE/GK3PYmZ2+vyYGCM7izZhwvu+R91R+/H/8l2/R9bMNEzAP8KnaeZmlkUFv/LmJVO t5DZ8qJgkXwHrbfHxFCKhUtWOAsQC0enwo6Vsdb6frte4JiU91meZUBlvtCfxg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1690386861; a=rsa-sha256; cv=none; b=Ccw1PCyv4E2SkEDH6Rdv1h5gIuRAakMkYKuVIXf4Z3uUJk4jjZc6zLOldZDqcyFJdKrrMs bxcLEFC4Nd6wgUOsYdkQraz0sIAp8WvyW/T5ItifgjPym4Zu0xLKot7NhsYmJ8Uy8//xo7 vV69a9btMfeyz1d/a8EKq09m8MfvundMjk5X6gwDaOOagF07mzs/tSdnSM7OuHovjVRWA6 Nva2YswijaRqO2UXsoHWuPKOYUcWjoJnE3FQRsoPymHtlvGHhTnYFMQAu1kwmmEBZuDpQW fwXQJkfvmYc2rVwRAJELnBgTuMfNyJfRCTqvHmk6bPL/pvhMu1YHc9stytXGzw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=foundationdevices.com header.s=google header.b=GpSKM78a; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gnu.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qOgb0-0007ZQ-Sz; Wed, 26 Jul 2023 11:38:38 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qOgaW-0007Tr-FO for guix-patches@gnu.org; Wed, 26 Jul 2023 11:38:08 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qOgaV-0004qL-QM; Wed, 26 Jul 2023 11:38:07 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qOgaP-0003yK-W5; Wed, 26 Jul 2023 11:38:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#64874] [PATCH] guix: tuned-package: Use target on cross-compile. Resent-From: Jean-Pierre De Jesus DIAZ Original-Sender: "Debbugs-submit" Resent-CC: mail@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Wed, 26 Jul 2023 15:38:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 64874 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 64874@debbugs.gnu.org Cc: Jean-Pierre De Jesus DIAZ , mail@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr X-Debbugs-Original-To: guix-patches@gnu.org X-Debbugs-Original-Xcc: mail@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr Received: via spool by submit@debbugs.gnu.org id=B.169038587215250 (code B ref -1); Wed, 26 Jul 2023 15:38:01 +0000 Received: (at submit) by debbugs.gnu.org; 26 Jul 2023 15:37:52 +0000 Received: from localhost ([127.0.0.1]:49881 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qOgaG-0003xu-1Z for submit@debbugs.gnu.org; Wed, 26 Jul 2023 11:37:52 -0400 Received: from lists.gnu.org ([2001:470:142::17]:58996) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qOgaC-0003xg-LG for submit@debbugs.gnu.org; Wed, 26 Jul 2023 11:37:49 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qOga5-00077k-Dv for guix-patches@gnu.org; Wed, 26 Jul 2023 11:37:43 -0400 Received: from mail-wr1-x436.google.com ([2a00:1450:4864:20::436]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qOga3-0004gf-5J for guix-patches@gnu.org; Wed, 26 Jul 2023 11:37:41 -0400 Received: by mail-wr1-x436.google.com with SMTP id ffacd0b85a97d-3159d5e409dso838842f8f.0 for ; Wed, 26 Jul 2023 08:37:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=foundationdevices.com; s=google; t=1690385853; x=1690990653; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=TVgOWdWsXw1xxsq3WDTo/GcgGSoVbMHVqhzrmLCFt0I=; b=GpSKM78apMC1Ir0QqBQt1tm4kdHzOvnN8yoNBfdC+qng1wcr/lICxWdCLcaYnP1EOB aNXFR7b0b+BHBtFxWEwosLsvQ+qzuXgewOmX0/Oa1DPACio+jRbYep1HAzd2Ko2bnxwi 4tnabWwe83h04R7KO/8Jxjg5LIfx7blA/3e1XNirlYht61c76YcEXdXhrp7JGXo445u7 C9kmeGUCg7LSj1NvtJBV0oyQQ687Ig0azF+q+0e2jE+oczrR7mY5JjdGqflYuQ4nRGGf IpR1C0WfjKy6fuPl/WFBeMZsKNC5it6qvA6/mTcxnVyk6lYo4/p1A2viB4HxYuudzIid Ij9Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1690385853; x=1690990653; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=TVgOWdWsXw1xxsq3WDTo/GcgGSoVbMHVqhzrmLCFt0I=; b=OJ5HFIq9/CBNONi2ftpugvReBS/LqhbXmEV0JnO32QEpXrB9k8oQ4bZ54anJuHAisX z+MxW1gMAlUHxhP4uelQjdbl/epQsKxBsg/HyHM5QO0MCNrEb5C8gYbjFUm540xEWMie nJeF+FmQpRrrOUKtluINbvWP3+ltksXrwpmE7ACwfWZivWwTvHBTnna+iciB9BMQf2uT u1hMXEFVPnI73idgaT98IHTlAsDJkcyeqNVTWSr+bETePATaNP3ppqfwQkpI/KN4jogV /B8d1cUH53Yts5i7o00xZp1ICbQI2iU476WJLHnY1+awXayByx9BQ+JQIV2YbWM9HVLY nVeg== X-Gm-Message-State: ABy/qLbT0yATEE8ilXzE3vhLoE6YIreHaXzciQE7+vmBxUlzsYQENUxt 2l5bJOuXFN88KUKsz/j0dsI0X3mlbtNE4cQDvtKq6A== X-Google-Smtp-Source: APBJJlHAl2RF9wiCRDcO1Iw8O0j+U2TIo71tTZ8DlnoZB7d6IRNz05XPO/cQcC1T4pwlbvgXeW2QnA== X-Received: by 2002:adf:e651:0:b0:317:6c3:c94d with SMTP id b17-20020adfe651000000b0031706c3c94dmr2342478wrn.14.1690385853702; Wed, 26 Jul 2023 08:37:33 -0700 (PDT) Received: from omen15.home ([89.131.29.87]) by smtp.gmail.com with ESMTPSA id s14-20020adfea8e000000b003143be36d99sm20172710wrm.58.2023.07.26.08.37.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 26 Jul 2023 08:37:33 -0700 (PDT) Date: Wed, 26 Jul 2023 17:37:29 +0200 Message-Id: <20230726153729.4147922-1-jean@foundationdevices.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2a00:1450:4864:20::436; envelope-from=jean@foundationdevices.com; helo=mail-wr1-x436.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-to: Jean-Pierre De Jesus DIAZ X-ACL-Warn: , Jean-Pierre De Jesus DIAZ via Guix-patches From: Jean-Pierre De Jesus DIAZ via Guix-patches via Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Scanner: mx2.migadu.com X-Migadu-Spam-Score: -4.64 X-Spam-Score: -4.64 X-Migadu-Queue-Id: 9F261452C1 X-TUID: ZvUlgLPIwcYb * 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: Jean-Pierre De Jesus DIAZ --- guix/transformations.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/guix/transformations.scm b/guix/transformations.scm index 92d9c89c0e..76d0208bf1 100644 --- a/guix/transformations.scm +++ b/guix/transformations.scm @@ -510,8 +510,9 @@ (define (lower* . args) ;; 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) . _) base-commit: cf9904bcc8dd03e73675475bb4d8746dc434e415 -- 2.34.1