From patchwork Mon Sep 6 04:59:02 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Philip McGrath X-Patchwork-Id: 32655 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 16CCE27BBE3; Mon, 6 Sep 2021 06:00:36 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,T_DKIM_INVALID, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 85D9327BBE1 for ; Mon, 6 Sep 2021 06:00:35 +0100 (BST) Received: from localhost ([::1]:58404 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mN6kD-0003pD-R2 for patchwork@mira.cbaines.net; Mon, 06 Sep 2021 01:00:33 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:39600) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mN6ji-0003oT-CW for guix-patches@gnu.org; Mon, 06 Sep 2021 01:00:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:39792) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mN6ji-0007Fc-1b for guix-patches@gnu.org; Mon, 06 Sep 2021 01:00:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mN6jh-0005GY-Ui for guix-patches@gnu.org; Mon, 06 Sep 2021 01:00:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#50419] [PATCH 1/2] gnu: racket: fix `raco exe` with non-minimal Racket Resent-From: Philip McGrath Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 06 Sep 2021 05:00:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50419 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 50419@debbugs.gnu.org Cc: Philip McGrath Received: via spool by 50419-submit@debbugs.gnu.org id=B50419.163090437120166 (code B ref 50419); Mon, 06 Sep 2021 05:00:01 +0000 Received: (at 50419) by debbugs.gnu.org; 6 Sep 2021 04:59:31 +0000 Received: from localhost ([127.0.0.1]:51335 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mN6jC-0005FB-SB for submit@debbugs.gnu.org; Mon, 06 Sep 2021 00:59:31 -0400 Received: from mail-qv1-f49.google.com ([209.85.219.49]:33543) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mN6jB-0005Ey-BS for 50419@debbugs.gnu.org; Mon, 06 Sep 2021 00:59:29 -0400 Received: by mail-qv1-f49.google.com with SMTP id a5so3406073qvq.0 for <50419@debbugs.gnu.org>; Sun, 05 Sep 2021 21:59:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=philipmcgrath.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=6T8xFL/vyZu/Dw1Ux5QiAZ0M/RTSVBB38hK7fOwQs38=; b=Zh3rFDY6o44l8C3YQVpJCGYOreOMzHQqXOsA0xMIGFDRwtRAC6h3jwPJeoL6qmzo3I /y++c4Ip+/aQpvpJlqHnrJ7Ru+xWkIDuNve/vqTWGbPqBzbtnxZ6u8g3cnzxuUdGsaHj BRI13wEaqNMVcwVyJwNTRKABks9qZ14cTpLYsARXSWxZz5VdwY4C5e+qXL64H5H6JNuT 6uyjU6zjjnr7nxdomolux56c7+EsB/gHdtfxwAxMBn0CBfzgkAQoBhaky8LYwcY7DqGM iLSAd3BhOcSoFdnPQpA9zWQOC5ZJb60t07jJAv+6UZisSRAB6/aQ5f2OMRiE1brANAZo 8isg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=6T8xFL/vyZu/Dw1Ux5QiAZ0M/RTSVBB38hK7fOwQs38=; b=H5KOaFQN/dt1PaYGetyVBOGRquqAD5F2/c3VxRk4Yx9XXLG0CwCiYbmQSylOieP7A7 hk5JTJAPpEaWZuohUxgVwAVlZrwSLbra4jOTVFhMPgXcgdUjF/RUJpK2WqcTXPuG+zfU NGeDiItH2XRbSymgF99YGIBy2IhdTu/XJjdNw7nPtDBakIZkmS9a3sGtg9DIlT7/KiEv kCw9+0CboP4/+KskUa79tGIFp8+pzHumIqH5hyqSUKHjdtxwaT4iBG7AE2qwWr6Sgktg 346C3DQDLwDD6SPIuBaTWA30Xcq8E1+0RRnjpMy3OTCo6klqckm5ocXFOLYCLhyAztAK uBgQ== X-Gm-Message-State: AOAM530TZ0Ete0525MSZ5d7YcW/LFlk6eoOZPLsD5bYZdYtxqqSjx+qk 34DAAMDL0JhZqdok9i9RKTiPwjTN/03AZwNs X-Google-Smtp-Source: ABdhPJwAgmSo/rWopJPAzjQKjvC1Dr2lzKktPDIf0KdxIWsv8AyC3RMrr8qti0LxTe3ZBD/2dsfIsw== X-Received: by 2002:a0c:df04:: with SMTP id g4mr10476183qvl.10.1630904363562; Sun, 05 Sep 2021 21:59:23 -0700 (PDT) Received: from localhost ([2601:589:4900:c80:3d4:6a56:4476:ffaf]) by smtp.gmail.com with ESMTPSA id q10sm6029414qke.108.2021.09.05.21.59.23 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 05 Sep 2021 21:59:23 -0700 (PDT) From: Philip McGrath Date: Mon, 6 Sep 2021 00:59:02 -0400 Message-Id: <20210906045903.478751-1-philip@philipmcgrath.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210906045503.477260-1-philip@philipmcgrath.com> References: <20210906045503.477260-1-philip@philipmcgrath.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: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches This commit backports an upstream repair for a bug exposed by Guix's change in Racket 8.2 to make the `racket` package a layered/tethered installation that chains to the `racket-minimal` package. When using a layered/tethered installation, the `setup/variant` library would fail to recognize the default Racet variant (CS, 3M, or CGC), leading to confusing failures from `raco exe`, `create-embedding-executable`, and other clients. For further details, see and . * gnu/packages/patches/racket-minimal-backport-1629887.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/racket.scm (racket-minimal)[source]: Use it. --- gnu/local.mk | 1 + .../racket-minimal-backport-1629887.patch | 28 +++++++++++++++++++ gnu/packages/racket.scm | 4 ++- 3 files changed, 32 insertions(+), 1 deletion(-) create mode 100644 gnu/packages/patches/racket-minimal-backport-1629887.patch diff --git a/gnu/local.mk b/gnu/local.mk index f848a8c61f..655e55df45 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1701,6 +1701,7 @@ dist_patch_DATA = \ %D%/packages/patches/ripperx-missing-file.patch \ %D%/packages/patches/rpcbind-CVE-2017-8779.patch \ %D%/packages/patches/rtags-separate-rct.patch \ + %D%/packages/patches/racket-minimal-backport-1629887.patch \ %D%/packages/patches/racket-minimal-sh-via-rktio.patch \ %D%/packages/patches/remake-impure-dirs.patch \ %D%/packages/patches/restic-0.9.6-fix-tests-for-go1.15.patch \ diff --git a/gnu/packages/patches/racket-minimal-backport-1629887.patch b/gnu/packages/patches/racket-minimal-backport-1629887.patch new file mode 100644 index 0000000000..aa060ef5aa --- /dev/null +++ b/gnu/packages/patches/racket-minimal-backport-1629887.patch @@ -0,0 +1,28 @@ +From fb1a6ab205fd63a46669a463931af473e2ac0c87 Mon Sep 17 00:00:00 2001 +From: Matthew Flatt +Date: Sat, 21 Aug 2021 15:29:59 -0600 +Subject: [PATCH] setup/variant: recognize starter executables + +Related to #3969 + +(cherry picked from commit 1629887071fe3cc8fe8af0a7aa0d3912509cb058) +--- + racket/collects/setup/variant.rkt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/racket/collects/setup/variant.rkt b/racket/collects/setup/variant.rkt +index 81da6f5701..b23131e481 100644 +--- a/racket/collects/setup/variant.rkt ++++ b/racket/collects/setup/variant.rkt +@@ -25,7 +25,7 @@ + (and (file-exists? f) + (with-input-from-file f + (lambda () +- (define m (regexp-match #rx#"bINARy tYPe:..(.)" ++ (define m (regexp-match #rx#"bINARy tYPe:e?..(.)" + (current-input-port))) + (cond + [(not m) '3m] +-- +2.30.2 + diff --git a/gnu/packages/racket.scm b/gnu/packages/racket.scm index 4bc34193c6..a05d435303 100644 --- a/gnu/packages/racket.scm +++ b/gnu/packages/racket.scm @@ -138,7 +138,9 @@ (sha256 "061bhiyjlvazph0dj9i3i3x2q5z53rp8h5cjwg3frjimkr45lncn") (file-name (git-file-name name version)) - (patches (search-patches "racket-minimal-sh-via-rktio.patch")) + (patches (search-patches "racket-minimal-sh-via-rktio.patch" + ;; Remove the following in version 8.3 + "racket-minimal-backport-1629887.patch")) (snippet (with-imported-modules '((guix build utils)) #~(begin