From patchwork Tue May 23 16:11:11 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Janneke Nieuwenhuizen X-Patchwork-Id: 13265 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 7130327BBEC; Tue, 23 May 2023 17:12:24 +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=-3.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS, URIBL_BLOCKED autolearn=ham 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 8516E27BBE9 for ; Tue, 23 May 2023 17:12:23 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1q1UcH-0006lA-3z; Tue, 23 May 2023 12:12:05 -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 1q1UcE-0006au-WF for guix-patches@gnu.org; Tue, 23 May 2023 12:12:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1q1UcE-0003tz-Jr for guix-patches@gnu.org; Tue, 23 May 2023 12:12:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1q1UcD-0000HG-Vq for guix-patches@gnu.org; Tue, 23 May 2023 12:12:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#63641] [PATCH 2/8] gnu: glibc/hurd-headers: Properly cross-build. Resent-From: Janneke Nieuwenhuizen Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 23 May 2023 16:12:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 63641 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 63641@debbugs.gnu.org Cc: dev@jpoiret.xyz X-Debbugs-Original-To: Josselin Poiret via Guix-patches via X-Debbugs-Original-Cc: Josselin Poiret , 63641@debbugs.gnu.org Received: via spool by submit@debbugs.gnu.org id=B.16848582881006 (code B ref -1); Tue, 23 May 2023 16:12:01 +0000 Received: (at submit) by debbugs.gnu.org; 23 May 2023 16:11:28 +0000 Received: from localhost ([127.0.0.1]:40294 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q1Ubf-0000GA-RT for submit@debbugs.gnu.org; Tue, 23 May 2023 12:11:28 -0400 Received: from lists.gnu.org ([209.51.188.17]:48710) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q1Ube-0000G1-DC for submit@debbugs.gnu.org; Tue, 23 May 2023 12:11:27 -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 1q1UbX-0005h5-VC for guix-patches@gnu.org; Tue, 23 May 2023 12:11:20 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q1UbW-0003mq-U6; Tue, 23 May 2023 12:11:18 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:In-Reply-To:Date:References:Subject:To: From; bh=9Fu+vIfYel1FaGR6temqXXvy/pfH2vsx1CKasJwmklI=; b=NHbSkh+1MR/ewq0n1mhV fvqk5I34JBEU0OcSBJvR3LLFHP2QDq35vCg4fR6SBzJNlcXasOY2f4C3eTIuHdnMM4TdzzqNvPJug 12uUnQdpQi5KfaMLC2CLiXYMHxxE5mPYiKt+q04gHv/vN7xL9nnJLf9eby2s6FbaBtQuPIjmn1EAx Z/QNRxatoqYJc0iNQndwPjOikXkbR/5YlsXUAILA4kusAj93u/s79E+W2AMfnBUpLjbL8ayFxqPZ3 9HINV9iWv16Qto8xOhdpv5loKrtG1LwJ1phWl9Fc7HXhUY0giVYyavincMUDhg5hXZy2UmzzpZiuJ N597NKtG6SnRhg==; Received: from 2a02-a462-da03-1-2701-7f81-a736-4607.fixed6.kpn.net ([2a02:a462:da03:1:2701:7f81:a736:4607] helo=drakenpad.janneke.lilypond.org) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q1UbV-0002ra-MK; Tue, 23 May 2023 12:11:18 -0400 From: Janneke Nieuwenhuizen Organization: AvatarAcademy.nl References: <873b5a865c24b22b98332cc6f26e2ebef31ae68b.1684745752.git.dev@jpoiret.xyz> X-Url: http://AvatarAcademy.nl Date: Tue, 23 May 2023 18:11:11 +0200 In-Reply-To: <873b5a865c24b22b98332cc6f26e2ebef31ae68b.1684745752.git.dev@jpoiret.xyz> (Josselin Poiret via Guix-patches via's message of "Mon, 22 May 2023 11:04:12 +0200") Message-ID: <871qj73u5c.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) 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: , 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 Josselin Poiret via Guix-patches via writes: Hi! > From: Josselin Poiret > > * gnu/packages/base.scm (glibc/hurd-headers): Rely on cross-mig, and remove > hardcoded configure flag `--host=i586-pc-gnu`. > * gnu/packages/cross-base.scm (cross-kernel-headers*): Add `--host` and > `--build` configure flags. [..] > --- > gnu/packages/base.scm | 13 ++++++------- > gnu/packages/cross-base.scm | 6 +++++- > 2 files changed, 11 insertions(+), 8 deletions(-) > > diff --git a/gnu/packages/base.scm b/gnu/packages/base.scm > index d2f276c447..f944ab5d47 100644 > --- a/gnu/packages/base.scm > +++ b/gnu/packages/base.scm > @@ -1423,17 +1423,15 @@ (define-public glibc/hurd-headers > (native-inputs > (modify-inputs (package-native-inputs glibc) > (prepend (if (%current-target-system) > - ;; XXX: When targeting i586-pc-gnu, we need a 32-bit MiG, > - ;; hence this hack. > - (package (inherit mig) > - (arguments `(#:system "i686-linux"))) > - mig)))) > + (let* ((cross-base (resolve-interface '(gnu packages cross-base))) > + (cross-mig (module-ref cross-base 'cross-mig))) > + (cross-mig (%current-target-system))) > + mig)))) I believe you can just do --8<---------------cut here---------------start------------->8--- --8<---------------cut here---------------end--------------->8--- (Learnt that from "someone" https://issues.guix.gnu.org/63527#27 ;) Otherwise, LGTM! Greetings, Janneke diff --git a/gnu/packages/base.scm b/gnu/packages/base.scm index 59c9632551..cdeb3f0a4e 100644 --- a/gnu/packages/base.scm +++ b/gnu/packages/base.scm @@ -53,6 +53,7 @@ (define-module (gnu packages base) #:use-module (gnu packages guile) #:use-module (gnu packages multiprecision) #:use-module (gnu packages compression) + #:use-module (gnu packages cross-base) #:use-module (gnu packages perl) #:use-module (gnu packages linux) #:use-module (gnu packages pcre) @@ -1446,9 +1447,7 @@ (define-public glibc/hurd-headers (native-inputs (modify-inputs (package-native-inputs glibc/hurd) (prepend (if (%current-target-system) - (let* ((cross-base (resolve-interface '(gnu packages cross-base))) - (cross-mig (module-ref cross-base 'cross-mig))) - (cross-mig (%current-target-system))) + (cross-mig (%current-target-system)) mig)))) (arguments (substitute-keyword-arguments (package-arguments glibc/hurd)