From patchwork Tue Nov 19 06:55:15 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Janneke Nieuwenhuizen X-Patchwork-Id: 70532 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 A1B2327BBEA; Tue, 19 Nov 2024 07:00:32 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-7.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED, RCVD_IN_VALIDITY_CERTIFIED,RCVD_IN_VALIDITY_RPBL,RCVD_IN_VALIDITY_SAFE, 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 5ADCB27BBE2 for ; Tue, 19 Nov 2024 07:00:32 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tDIDY-0000k7-J2; Tue, 19 Nov 2024 02:00:08 -0500 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 1tDIDW-0000hL-1I for guix-patches@gnu.org; Tue, 19 Nov 2024 02:00:06 -0500 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 1tDIDV-0004ge-C0 for guix-patches@gnu.org; Tue, 19 Nov 2024 02:00:05 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:References:In-Reply-To:Date:From:To:Subject; bh=vc6TmPsZt9gRfGUT3TPTCxPOTd6Do/TxOPguHB3OS0M=; b=HXh88mfooJdd/+ZzGkSo7LfxjYXJT0PIzqQINuB0/JJUZR6ozCkEW1rl9FlCzmzaKx+9HWE+6+YJAKzJ97VqER5clOQ3CUo25wbsXvyWUXvR5mCFJqoYV3Q6rsKgFwSbrfRTYoFL9umAEgWb/Mx46sY6DVSaZeqvM3gwNFDKHLt1JH6vdjEJGq37YUkxyjWn9meL0GXb0dR3D52Jh7sePheQO/iMf0tdmomtWHg8qA9khyWW8pQxjaAWs8v84LuiaTHuAoj3nI7ZEVpOrW07diJxebuo3Db3cI/w0gW38dymzUyigw/sDUlAvuI+aZRjBBEvHk7axr3q1bAxHhYS3Q==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tDIDV-0005OW-6H for guix-patches@gnu.org; Tue, 19 Nov 2024 02:00:05 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#74290] [PATCH v3 45/51] gnu: gettext: Fix cross-build shebangs. Resent-From: Janneke Nieuwenhuizen Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 19 Nov 2024 07:00:05 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74290 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 74290@debbugs.gnu.org Received: via spool by 74290-submit@debbugs.gnu.org id=B74290.173199959020577 (code B ref 74290); Tue, 19 Nov 2024 07:00:05 +0000 Received: (at 74290) by debbugs.gnu.org; 19 Nov 2024 06:59:50 +0000 Received: from localhost ([127.0.0.1]:40657 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tDIDF-0005Lg-Pv for submit@debbugs.gnu.org; Tue, 19 Nov 2024 01:59:50 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43482) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tDICO-0005CE-8h for 74290@debbugs.gnu.org; Tue, 19 Nov 2024 01:58:56 -0500 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 1tDIAC-00046X-Vx; Tue, 19 Nov 2024 01:56:41 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=vc6TmPsZt9gRfGUT3TPTCxPOTd6Do/TxOPguHB3OS0M=; b=o7pIBpAK+DsLPtYzorEM tpcRdL3uTIHzZUQYJtL/YSrQVxovPRUn88wI2Dq+zlqoxUEEbfMo/fOtMCZ6vFb4ixFvTie+p38K0 N/kv1n6tKYodO9qtpZj+t6/0JZHtmW8gS+RFGwWXhTK0nlStTjfAWP2MxykXsAvF8iKLzVo3d3p9O OvevAQh47S+naBxLeoNf6nLTV3DuDSMDPUpse5P6Knxnfl8Yl4XAgZ10lfwOhLmg5SruYPC9JScFL SggyZKqxcHvAlGYBB7CyGEeSpG8NghQ+ZdqGFtlN+8A43CSAg7AeJtB4yjiAhfkVdutFDoOukPfWM HunmlZIDdZLq7g==; From: Janneke Nieuwenhuizen Date: Tue, 19 Nov 2024 07:55:15 +0100 Message-ID: X-Mailer: git-send-email 2.46.0 In-Reply-To: References: 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 This fixes running autopoint from a cross-built gettext[-minimal]. * gnu/packages/gettext.scm (gettext-minimal): When cross-building, add stage "patch-cross-shebangs". Change-Id: I5029a3be0b5cee3c173de66d8f0b027b02c3bc47 --- gnu/packages/gettext.scm | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/gnu/packages/gettext.scm b/gnu/packages/gettext.scm index cabe4f3be9..7862c296bd 100644 --- a/gnu/packages/gettext.scm +++ b/gnu/packages/gettext.scm @@ -9,7 +9,7 @@ ;;; Copyright © 2017 Eric Bavier ;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice ;;; Copyright © 2019 Miguel -;;; Copyright © 2020, 2023 Janneke Nieuwenhuizen +;;; Copyright © 2020, 2023, 2024 Janneke Nieuwenhuizen ;;; Copyright © 2020 EuAndreh ;;; Copyright © 2022, 2024 gemmaro ;;; Copyright © 2023 Maxim Cournoyer maxim.cournoyer@gmail.com> @@ -130,7 +130,19 @@ (define-public gettext-minimal ((" test-tls\\$\\(EXEEXT\\) ") " "))) '()) - #t))))) + #t)))) + #$@(if (%current-target-system) + #~((add-after 'install 'patch-cross-shebangs + (lambda _ + (let ((path (list (string-append #$bash-minimal "/bin")))) + (define (patch-cross-shebang file) + (patch-shebang file path)) + (with-directory-excursion + (string-append #$output "/bin") + (for-each + patch-cross-shebang + '("autopoint" "gettext.sh" "gettextize"))))))) + '())) ;; When tests fail, we want to know the details. #:make-flags #~'("VERBOSE=yes")))