From patchwork Fri Sep 29 09:16:09 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jean-Pierre De Jesus DIAZ X-Patchwork-Id: 54387 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id C56E727BBE9; Fri, 29 Sep 2023 10:18:10 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id B735527BBE2 for ; Fri, 29 Sep 2023 10:18:09 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qm9dI-0005UZ-TM; Fri, 29 Sep 2023 05:18:02 -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 1qm9d6-0005SU-Qc for guix-patches@gnu.org; Fri, 29 Sep 2023 05:17:51 -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 1qm9d6-0003tw-Iq for guix-patches@gnu.org; Fri, 29 Sep 2023 05:17:48 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qm9dL-0004lH-83; Fri, 29 Sep 2023 05:18:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#66263] [PATCH 05/23] gnu: cross-gcc: Enable multilib for avr. Resent-From: Jean-Pierre De Jesus DIAZ Original-Sender: "Debbugs-submit" Resent-CC: efraim@flashner.co.il, vagrant@debian.org, maxim.cournoyer@gmail.com, guix-patches@gnu.org Resent-Date: Fri, 29 Sep 2023 09:18:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 66263 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 66263@debbugs.gnu.org Cc: Jean-Pierre De Jesus DIAZ , efraim@flashner.co.il, vagrant@debian.org, maxim.cournoyer@gmail.com X-Debbugs-Original-Xcc: efraim@flashner.co.il, vagrant@debian.org, maxim.cournoyer@gmail.com Received: via spool by 66263-submit@debbugs.gnu.org id=B66263.169597903518014 (code B ref 66263); Fri, 29 Sep 2023 09:18:03 +0000 Received: (at 66263) by debbugs.gnu.org; 29 Sep 2023 09:17:15 +0000 Received: from localhost ([127.0.0.1]:55181 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qm9cY-0004gO-HI for submit@debbugs.gnu.org; Fri, 29 Sep 2023 05:17:14 -0400 Received: from mail-wm1-x32e.google.com ([2a00:1450:4864:20::32e]:53631) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qm9cM-0004dv-Hy for 66263@debbugs.gnu.org; Fri, 29 Sep 2023 05:17:09 -0400 Received: by mail-wm1-x32e.google.com with SMTP id 5b1f17b1804b1-4053c6f0db8so133747335e9.3 for <66263@debbugs.gnu.org>; Fri, 29 Sep 2023 02:16:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=foundationdevices.com; s=google; t=1695979000; x=1696583800; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=3Tmr9YlDYp4sxolPKptevR6pMJkVG+GvEjNbzj73Nx0=; b=DOTT/SRobUyKPZXQ8wUcYAA4+LmrE3CQWYVxSwQYO7jKbiQjitbHMVIPH3W2NyOMRB L1O5KN0r//Z5bwfxx/wVvyK+ghwMLa7p4KMHJGSojhzptLXFWBKGicSK3En78Fq2ioNt ViM4JJUuMfmffvkeOQ/lDearxoyLmsGZU4NlSpKdneqjG/OgxZ/hcVKEvoKRWq7nNOFm snB2hUY1FP88pRCS2DecDLPu5CJ3OPt+4+6ofxc7JOjbGJcqVk/Hq1bG8A1K3q+qmq3k ORCzXEilmOgMKCkxZRtqmYVfv4CfqFmwavJhioZXvWqHYZ7jPVe7oiNlp1+ibgiblMya 7liQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695979000; x=1696583800; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=3Tmr9YlDYp4sxolPKptevR6pMJkVG+GvEjNbzj73Nx0=; b=mI2rIEHaI82y1AS7E/ExjuGOdj7qWTkjhcA7Gym2CgDaPuZvUlGOkM2mfRrDCbdiRj T2uWTwFcWxbK10ha+NFgTr/taBS0ZMXBQvpqVdky/9W+SEK5+pXeuSL6XuyE7YiWFbfC fULAxLCPMzW0ZfWBnW2CaANctSGvFlPsjHmR1ITJNUb+5AJEZUNGt3w0IcF1l99PZH4L AqNrIxl/NMZ5g+LHeHr/+IG0FwygigO3T8vo45lJwufkKe2YrKsiqDj+d/J5v5rphNo/ zy6oP9I10wV6AWLPmi77ESUnP05VMkzTee1y6lRYhzPmssU/mfVwOjC5tgF1nXQCykJg yesQ== X-Gm-Message-State: AOJu0Yx8DdV6k0WpJrW5kxSdOVv/r6T/UUwKkB0RYHUqF+GYdvzXqf9+ Fud5x+ref40O4RbzltUXfv5ryFOqV/0jbWFGGFp3rg== X-Google-Smtp-Source: AGHT+IEXdn7dYhe8SXdIb8+GgrzeDc4cnq0q9K6X7pjjfRBXYKR9nOsFxwUCjCzomprD6T9BWS2AcQ== X-Received: by 2002:a05:600c:2286:b0:3fd:2e89:31bd with SMTP id 6-20020a05600c228600b003fd2e8931bdmr3358502wmf.14.1695978999678; Fri, 29 Sep 2023 02:16:39 -0700 (PDT) Received: from omen15.home ([89.131.29.87]) by smtp.gmail.com with ESMTPSA id k15-20020a7bc40f000000b004013797efb6sm1020933wmi.9.2023.09.29.02.16.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Sep 2023 02:16:39 -0700 (PDT) Date: Fri, 29 Sep 2023 11:16:09 +0200 Message-Id: <20230929091627.7820-5-jean@foundationdevices.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230929091627.7820-1-jean@foundationdevices.com> References: <20230929091627.7820-1-jean@foundationdevices.com> MIME-Version: 1.0 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 X-Patchwork-Original-From: Jean-Pierre De Jesus DIAZ via Guix-patches via From: Jean-Pierre De Jesus DIAZ Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/cross-base.scm (cross-gcc-arguments) [target-avr?]: Remove --disable-mutlilib and add --enable-multilib. --- gnu/packages/avr.scm | 4 +--- gnu/packages/cross-base.scm | 17 +++++++++++++---- 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/gnu/packages/avr.scm b/gnu/packages/avr.scm index b9bee5e624..e976203b89 100644 --- a/gnu/packages/avr.scm +++ b/gnu/packages/avr.scm @@ -75,9 +75,7 @@ (define avr-gcc ;; several scripts inside this script, each with a #!/bin/sh ;; that needs patching. (substitute* "gcc/genmultilib" - (("#!/bin/sh") (string-append "#!" (which "sh")))))))) - ((#:configure-flags flags) - #~(delete "--disable-multilib" #$flags)))) + (("#!/bin/sh") (string-append "#!" (which "sh")))))))))) (native-search-paths (list (search-path-specification (variable "CROSS_C_INCLUDE_PATH") diff --git a/gnu/packages/cross-base.scm b/gnu/packages/cross-base.scm index f55765f1b0..ec7ca2186d 100644 --- a/gnu/packages/cross-base.scm +++ b/gnu/packages/cross-base.scm @@ -197,12 +197,21 @@ (define (cross-gcc-arguments target xgcc libc) #~((string-append "--with-toolexeclibdir=" (assoc-ref %outputs "lib") "/" #$target "/lib")) + #~()) + + #$@(if (target-avr? target) + #~("--enable-multilib") + #~()) + #~())) - #$(if libc - flags - #~(remove (cut string-match "--enable-languages.*" <>) - #$flags)))) + (remove + (lambda (flag) + (or (and (string-match "--enable-languages.*" flag) + #$libc) + (and (string-match "--disable-multilib" flag) + #$(target-avr? target)))) + #$flags))) ((#:make-flags flags) (if libc #~(let ((libc (assoc-ref %build-inputs "libc")))