From patchwork Mon Mar 8 02:53:48 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christopher Marusich X-Patchwork-Id: 27534 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 2CF7327BC51; Mon, 8 Mar 2021 02:55:16 +0000 (GMT) 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_ADSP_CUSTOM_MED, DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL,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 D870F27BC50 for ; Mon, 8 Mar 2021 02:55:12 +0000 (GMT) Received: from localhost ([::1]:59500 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lJ635-0002qC-Jx for patchwork@mira.cbaines.net; Sun, 07 Mar 2021 21:55:11 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:50136) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lJ62w-0002p1-QI for guix-patches@gnu.org; Sun, 07 Mar 2021 21:55:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:58511) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lJ62w-0004Lx-Ib for guix-patches@gnu.org; Sun, 07 Mar 2021 21:55:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lJ62w-0000NG-Gb for guix-patches@gnu.org; Sun, 07 Mar 2021 21:55:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#46987] core-updates: Emacs is only supported on x86_64-linux? Resent-From: Chris Marusich Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 08 Mar 2021 02:55:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 46987 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Mark H Weaver , Leo Famulari , Christopher Baines Cc: guix-devel@gnu.org Received: via spool by 46987-submit@debbugs.gnu.org id=B46987.16151720481376 (code B ref 46987); Mon, 08 Mar 2021 02:55:02 +0000 Received: (at 46987) by debbugs.gnu.org; 8 Mar 2021 02:54:08 +0000 Received: from localhost ([127.0.0.1]:41824 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lJ61z-0000M1-OM for submit@debbugs.gnu.org; Sun, 07 Mar 2021 21:54:08 -0500 Received: from mail-pj1-f48.google.com ([209.85.216.48]:55884) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lJ61v-0000LU-Uq for 46987@debbugs.gnu.org; Sun, 07 Mar 2021 21:54:02 -0500 Received: by mail-pj1-f48.google.com with SMTP id t9so2214751pjl.5 for <46987@debbugs.gnu.org>; Sun, 07 Mar 2021 18:53:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=2mKfmuPjcz5wFWbsaz++ljqGyU+EP602olVYrWcFomk=; b=GdqOPkc8KXoczJBYRHi5xZBBS3HVy5oHegRjwVsaYDVpeRDn/KQqKK+LDwkBcGIZDJ VKY0NgWijIVXsLlEtKq+kzorRcP2lIqnN1rf0NJGiYr9UfOBHFwHCWyvr2hhedXQJQ/o 1EigyRfxBMdsq4QUSiuog2bzJ91UbmX/0UYWx8e3BqygvIPjF99pFXtnqzfQjUPiO4lF ZYz5jZQGDrosUyjO7VCZlekq+0RUo4uqZrcBL8avV95cuFuyYeotbIsthSoAhkr7d6rU 7RxraHfyVOk+bStE1XsH8FYu657QU9JcpflBcePCPGVV12cZitS91UfDt4Mw6Fhi84Lk kbng== 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:references:date:in-reply-to :message-id:user-agent:mime-version; bh=2mKfmuPjcz5wFWbsaz++ljqGyU+EP602olVYrWcFomk=; b=IRWDW3+wDlWg6V8BFeL/m8UrtoRTeNrL0jMcd1eGONkJ5BSA6j2jUU4iKOsRXhWSXd FM94JcYbU7IsQzL/6fwDOVHWSvLFTlFrsW6mwJ7okjSqxuDkcZL4+UHDwlWCR1ypzC5p WSzq/kS+oKItoy1wQSWb3QduUB+ZbHn9QoWRd7JL7oumDQ9U4DEa8sOlJ+M2H3w7HrzK KzHsrlGBnPrOrMq2CCAPdqIXRzag6dzo0lmctVSx0PF6R+Oy3w0WRGbysIxOmmjL72J/ 3FoVvq7v0xASjLid2v0Z55HeR4L5VDnEafgi1Q/b/iYXTJEqyFSGkY7Z3PDGarWwXDY+ UFAw== X-Gm-Message-State: AOAM533lISzneRvraNZLLs3pS0++gHWNoAh3s2sbbT9VGAOgZ85QXDot 8Ffz2eghV0/eSfLn76+9b113kwnKJbqNuA== X-Google-Smtp-Source: ABdhPJzPT+tMxO5xG2PubxLPZBKoQVHxLdI0N8wfnV4M2xlPg6nOI6X/w795m2i02HBDttrkv9QKXg== X-Received: by 2002:a17:90a:f986:: with SMTP id cq6mr22675982pjb.175.1615172033440; Sun, 07 Mar 2021 18:53:53 -0800 (PST) Received: from garuda-lan (c-24-18-44-142.hsd1.wa.comcast.net. [24.18.44.142]) by smtp.gmail.com with ESMTPSA id a1sm8567257pff.156.2021.03.07.18.53.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 07 Mar 2021 18:53:52 -0800 (PST) From: Chris Marusich References: <87a6rf5rd6.fsf@gmail.com> <87a6rf5rd6.fsf@gmail.com> <87r1krgs10.fsf@netris.org> <87a6rf5rd6.fsf@gmail.com> <87r1krgs10.fsf@netris.org> Date: Sun, 07 Mar 2021 18:53:48 -0800 In-Reply-To: <87r1krgs10.fsf@netris.org> (Mark H. Weaver's message of "Sun, 07 Mar 2021 05:46:24 -0500, Sun, 7 Mar 2021 18:40:42 -0500, Sun, 07 Mar 2021 13:41:22 +0000") Message-ID: <874khm5pab.fsf_-_@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (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" X-getmail-retrieved-from-mailbox: Patches Hi all, FYI, I'm sending this message to 46987@debbugs.gnu.org via Bcc, also. I'm not sure if that works, but we'll see... Mark H Weaver writes: > It's not intended. Emacs should certainly be supported on every system > that Guix supports. Thank you for confirming. That is what I expected. > For now, I suggest that Emacs should have input 'librsvg' only on > 'x86_64-linux' systems. Something like this (untested), for > core-updates: > > diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm > index 98061c93ae..de6101cf17 100644 > --- a/gnu/packages/emacs.scm > +++ b/gnu/packages/emacs.scm > @@ -71,6 +71,7 @@ > #:use-module (gnu packages xml) > #:use-module (gnu packages xorg) > #:use-module (guix utils) > + #:use-module (ice-9 match) > #:use-module (srfi srfi-1)) > > (define-public emacs > @@ -236,7 +237,10 @@ > ("libpng" ,libpng) > ("zlib" ,zlib) > > - ("librsvg" ,librsvg) > + ,@(match (or (%current-target-system) > + (%current-system)) > + ("x86_64-linux" `(("librsvg" ,librsvg))) > + (_ `())) > ("libxpm" ,libxpm) > ("libxml2" ,libxml2) > ("libice" ,libice) > > Ditto for all other packages with 'librsvg' as an optional dependency. I've confirmed that works for emacs, except that you actually have to also do it for gtk+, too, since rust gets pulled in via gtk+ also. So, something like this: What do you think about that? If there are no problems, I'll go ahead and commit it to core-updates. Note that because that patch re-orders the inputs, it causes emacs to be rebuilt, which should be fine because it's core-updates. It seemed better to group these two inputs in a single match clause, rather than scattering them in two different but basically identical match clauses just to keep their original ordering intact. Christopher Baines writes: > Chris Marusich writes: > >> I've noticed that the emacs package only supports x86_64-linux, at least >> on core-updates. Is that intended? > > The relevant commit [1] does mention the intent "Remove "i686-linux" > from supported systems.", but that does differ from my interpretation of > the change, which is only support x86_64-linux. > > 1: https://git.savannah.gnu.org/cgit/guix.git/commit/?id=0ed631866cc0b7cece2b0a0b50e39b37ae91bb67 > > I've sent a patch that should add back "support" for other systems: > > https://issues.guix.gnu.org/46987 > > That's for master at least, I haven't looked in to what the situation is > on core-updates. It's worth there checking if the build still fails. That patch doesn't apply on core-updates because that rust version doesn't seem to exist any more on core-updates. However, the same change applied to the right rust on core-updates does the trick, like this: Both of these patches fix the issue for me. After applying either one in isolation (on the wip-ppc64le branch, which was recently rebased onto core-updates), the list of supported systems for the emacs package correctly includes other systems, including powerpc64le-linux, and thus the tests/guix-package.sh test passes on my powerpc64le-linux system. I think both of these patches are important and needed. The patch to restore supported systems to the rust package is important because we will want rust to build successfully on many systems. The patch to only add gtk+ and librsvg inputs to emacs when the system is x86_64-linux is important because it would be advantageous to be able to use emacs without depending on rust on systems like powerpc64le-linux, where Rust support may not be great yet. It's also convenient for me, personally, because I don't really want to deal with Rust right now just to get Emacs working on powerpc64le-linux. Once I can build a Guix release binary for powerpc64le-linux, then I think I can start worrying more about Rust. I have taken the liberty of applying these patches to the wip-ppc64le branch as-is, since they work for me. I can remove them later if we don't like it. We will undoubtedly run into a similar situation with other packages going forward, like Mark mentioned. Debian ran into this very issue some time ago, and apparently it caused a bit of consternation: https://lwn.net/Articles/771355/ Apparently, powerpc64le-unknown-linux-gnu is a "Tier 2" Rust platform, which I guess means it's pretty well supported, but not as well as "Tier 1". I hope that we can get it all working, since librsvg is depended upon in some way or another by about 2700 packages (about 17% of the total Guix package collection). In the meantime, limiting the blast radius as needed, like Mark suggested, seems like the right thing to do until Rust support improves on other architectures. From e36c4cab40c5b97ffedc72acc586c0b560e7868e Mon Sep 17 00:00:00 2001 From: Chris Marusich Date: Sun, 7 Mar 2021 15:58:19 -0800 Subject: [PATCH] gnu: rust: Make it "supported" on all systems but i686-linux. * gnu/packages/rust.scm (rust-1.30)[supported-systems]: Instead of hard-coding this to just "x86_64-linux", calculate the supported systems by deleting "i686-linux" from %supported-systems. --- gnu/packages/rust.scm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gnu/packages/rust.scm b/gnu/packages/rust.scm index 70d19e089ab..98c553cb913 100644 --- a/gnu/packages/rust.scm +++ b/gnu/packages/rust.scm @@ -448,7 +448,9 @@ jemalloc = \"" jemalloc "/lib/libjemalloc_pic.a" "\" (search-path-specification (variable "LIBRARY_PATH") (files '("lib" "lib64"))))) - (supported-systems '("x86_64-linux")) + (supported-systems + (delete "i686-linux" ; fails to build, see bug #35519 + %supported-systems)) (synopsis "Compiler for the Rust progamming language") (description "Rust is a systems programming language that provides memory safety and thread safety guarantees.") -- 2.26.2