From patchwork Fri Apr 16 21:11:38 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Philip McGrath X-Patchwork-Id: 28595 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 B958A27BC77; Fri, 16 Apr 2021 23:22:20 +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_H4,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 2B05527BC6C for ; Fri, 16 Apr 2021 23:22:20 +0100 (BST) Received: from localhost ([::1]:49634 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXWqx-0001tX-Dj for patchwork@mira.cbaines.net; Fri, 16 Apr 2021 18:22:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:46998) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lXVlu-0001JC-RQ for guix-patches@gnu.org; Fri, 16 Apr 2021 17:13:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:58510) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lXVlu-0006X5-IR for guix-patches@gnu.org; Fri, 16 Apr 2021 17:13:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lXVlu-0004np-Dc for guix-patches@gnu.org; Fri, 16 Apr 2021 17:13:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#47829] [PATCH 3/4] gnu: racket: Racket inherits racket-minimal, not vice versa. Resent-From: Philip McGrath Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 16 Apr 2021 21:13:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 47829 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 47829@debbugs.gnu.org Cc: Philip McGrath Received: via spool by 47829-submit@debbugs.gnu.org id=B47829.161860753418387 (code B ref 47829); Fri, 16 Apr 2021 21:13:02 +0000 Received: (at 47829) by debbugs.gnu.org; 16 Apr 2021 21:12:14 +0000 Received: from localhost ([127.0.0.1]:41819 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXVl7-0004mU-GP for submit@debbugs.gnu.org; Fri, 16 Apr 2021 17:12:14 -0400 Received: from mail-qv1-f53.google.com ([209.85.219.53]:46657) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXVl4-0004mE-Ps for 47829@debbugs.gnu.org; Fri, 16 Apr 2021 17:12:11 -0400 Received: by mail-qv1-f53.google.com with SMTP id h3so13375427qve.13 for <47829@debbugs.gnu.org>; Fri, 16 Apr 2021 14:12:10 -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=np6yck9ReyKkUkJHBjECry7Gct7qnjrKAfYWZooji6I=; b=LVJq4ZhfrEuDRH+85x1h9cU/jogKC7h8Thh0wovl+s2OXj5Bz+VCb6m0Qdn9ITKo3g oH57nfzSjE8wGxTsCqu/tWhhVymmDa16ruOBMYLBK6/eURSuxb9i0n3/d8UQMK3Yidv/ RIDs1ndkNnpX98ZzW7xrQFfvXj7EXFP6yosfshaFmJEYWQoN1pCgzUbt6lFrZyYXYCOF Eo/oPI1b2BwzW6PxcDup/HR6vAEBW9Ky102JiviRCe212xIM0kZPLXsZr08J1eEW/2HM d3KLQoTbiph93vs1yMcNXoEkrRvX/D9Hv0i7H/JUkoR7JhOVawCYTsRXwohqaRSYjAZY fpwA== 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=np6yck9ReyKkUkJHBjECry7Gct7qnjrKAfYWZooji6I=; b=si8LzPM1h3XT34zdoA9mOYelP+w5ag1DZ+viQO7ZR914t8nyeVQe90WYzhaLs3M2qS njWzS6MgwhMq5O0Zn7yOUKJGXnObq46C5XsFUDrOgCAz6gv+7dlb904hVhJ9DGZgP1y7 +IcrmvoyLQVWSbAHs1v5FQ3YVR3qj4FMrek9oM1PFtCYqfsWOBjpqpGLPMGhAtCMeGHx 0oEYq5L9OXXjnfvlrgyiyRbKGw4S4d1ZgAoq44sZXhTEulU2m2hGVi4i0D4Qluzzd/qh 2qwZFkJGLny1SHJ0mlTtge1LPAYqwFcO6KicUeq+bj5lGqvH8D8VWIefXgmjdrrz8S58 cnZw== X-Gm-Message-State: AOAM532FoKNaHcvz2EIZZcqr9/Ra0o4DY/MUvCQcMNzDG+VM6evp8bhd tzdWhFncQ/R35NGARgTSm9EpMBts9SYMgNzIrrw= X-Google-Smtp-Source: ABdhPJyqLsNDmeVndMrFLdEawQFbglR3Bi7LsjDfXcZPvQI/0KjD7s8mQrmVVnx1oIyOMq0RkxXytg== X-Received: by 2002:ad4:4511:: with SMTP id k17mr8187164qvu.44.1618607524970; Fri, 16 Apr 2021 14:12:04 -0700 (PDT) Received: from localhost (c-73-125-89-242.hsd1.fl.comcast.net. [73.125.89.242]) by smtp.gmail.com with ESMTPSA id k17sm4492374qtp.26.2021.04.16.14.12.04 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 16 Apr 2021 14:12:04 -0700 (PDT) From: Philip McGrath Date: Fri, 16 Apr 2021 17:11:38 -0400 Message-Id: <20210416211139.21825-2-philip@philipmcgrath.com> X-Mailer: git-send-email 2.21.1 (Apple Git-122.3) In-Reply-To: <20210416211139.21825-1-philip@philipmcgrath.com> References: <20210416210822.21536-1-philip@philipmcgrath.com> <20210416211139.21825-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 By design, the `racket` package is equivalent to 'racket-minimal' plus 'raco pkg install -i main-distribution'. This switch brings the Guix packages a small step closer to that goal. * gnu/packages/racket.scm (racket-minimal, racket): Change 'racket-minimal' to be the base package and 'racket' to inherit from it. Move 'version', 'patches', 'home-page', 'build-system', 'arguments', and 'license' to 'racket-minimal'. * gnu/packages/racket.scm (racket)[inputs]: Rather than copy and pasting, use '(package-inputs racket-minimal)'. --- gnu/packages/racket.scm | 123 ++++++++++++++++++++-------------------- 1 file changed, 60 insertions(+), 63 deletions(-) diff --git a/gnu/packages/racket.scm b/gnu/packages/racket.scm index 6cb72e592c..73e00240de 100644 --- a/gnu/packages/racket.scm +++ b/gnu/packages/racket.scm @@ -47,23 +47,32 @@ #:use-module (gnu packages tls) #:use-module (gnu packages xorg)) -(define-public racket +(define-public racket-minimal (package - (name "racket") - (version "8.0") ; note: remember to also update racket-minimal! - (source (origin - (method url-fetch) - (uri (list (string-append "https://mirror.racket-lang.org/installers/" - version "/racket-src.tgz") - ;; this mirror seems to have broken HTTPS: - (string-append - "http://mirror.informatik.uni-tuebingen.de/mirror/racket/" - version "/racket-src.tgz"))) - (sha256 - (base32 - "047wpjblfzmf1msz7snrp2c2h0zxyzlmbsqr9bwsyvz3frcg0888")) - (patches (search-patches - "racket-sh-via-rktio.patch")))) + (name "racket-minimal") + (version "8.0") ; note: remember to also update racket! + (source + (origin + (method url-fetch) + (uri (list (string-append "https://mirror.racket-lang.org/installers/" + version "/racket-minimal-src.tgz") + ;; this mirror seems to have broken HTTPS: + (string-append + "http://mirror.informatik.uni-tuebingen.de/mirror/racket/" + version "/racket-minimal-src.tgz"))) + (sha256 "0mwyffw4gcci8wmzxa3j28h03h0gsz55aard8qrk3lri8r2xyg21") + (patches (search-patches + "racket-sh-via-rktio.patch")))) + (home-page "https://racket-lang.org") + (synopsis "Racket without bundled packages such as DrRacket") + (inputs + `(("openssl" ,openssl) + ("sqlite" ,sqlite) + ("sh" ,bash-minimal) + ("zlib" ,zlib) + ("zlib:static" ,zlib "static") + ("lz4" ,lz4) + ("lz4:static" ,lz4 "static"))) (build-system gnu-build-system) (arguments `(#:configure-flags @@ -164,15 +173,41 @@ "unixodbc" "libedit"))) #t))) - ;; XXX: how to run them? + ;; Tests are in packages like racket-test-core and + ;; main-distribution-test that aren't part of the main distribution. #:tests? #f)) + (description + "Racket is a general-purpose programming language in the Scheme family, +with a large set of libraries and a compiler based on Chez Scheme. Racket is +also a platform for language-oriented programming, from small domain-specific +languages to complete language implementations. + +The ``minimal Racket'' distribution includes just enough of Racket for you to +use @command{raco pkg} to install more. Bundled packages, such as the +DrRacket IDE, are not included.") + ;; https://download.racket-lang.org/license.html + (license (list lgpl3+ asl2.0 expat)))) + + +(define-public racket + (package/inherit + racket-minimal + (name "racket") + (version (package-version racket-minimal)) ; needed for origin uri to work + (source + (origin + (inherit (package-source racket-minimal)) + (uri (list (string-append "https://mirror.racket-lang.org/installers/" + version "/racket-src.tgz") + ;; this mirror seems to have broken HTTPS: + (string-append + "http://mirror.informatik.uni-tuebingen.de/mirror/racket/" + version "/racket-src.tgz"))) + (sha256 + (base32 + "047wpjblfzmf1msz7snrp2c2h0zxyzlmbsqr9bwsyvz3frcg0888")))) (inputs `(;; sqlite and libraries for `racket/draw' are needed to build the doc. - ("sh" ,bash-minimal) - ("zlib" ,zlib) - ("zlib:static" ,zlib "static") - ("lz4" ,lz4) - ("lz4:static" ,lz4 "static") ("cairo" ,cairo) ("fontconfig" ,fontconfig) ("glib" ,glib) @@ -184,12 +219,10 @@ ("libx11" ,libx11) ("mesa" ,mesa) ("mpfr" ,mpfr) - ("openssl" ,openssl) ("pango" ,pango) - ("sqlite" ,sqlite) ("unixodbc" ,unixodbc) - ("libedit" ,libedit))) - (home-page "https://racket-lang.org") + ("libedit" ,libedit) + ,@(package-inputs racket-minimal))) (synopsis "A programmable programming language in the Scheme family") (description "Racket is a general-purpose programming language in the Scheme family, @@ -199,40 +232,4 @@ languages to complete language implementations. The main Racket distribution comes with many bundled packages, including the DrRacket IDE, libraries for GUI and web programming, and implementations of -languages such as Typed Racket, R5RS and R6RS Scheme, Algol 60, and Datalog.") - ;; https://download.racket-lang.org/license.html - (license (list lgpl3+ asl2.0 expat)))) - -(define-public racket-minimal - (package - (inherit racket) - (name "racket-minimal") - (version (package-version racket)) - (source - (origin - (inherit (package-source racket)) - (uri (list (string-append "https://mirror.racket-lang.org/installers/" - version "/racket-minimal-src.tgz") - ;; this mirror seems to have broken HTTPS: - (string-append - "http://mirror.informatik.uni-tuebingen.de/mirror/racket/" - version "/racket-minimal-src.tgz"))) - (sha256 "0mwyffw4gcci8wmzxa3j28h03h0gsz55aard8qrk3lri8r2xyg21"))) - (synopsis "Racket without bundled packages such as DrRacket") - (inputs - `(("openssl" ,openssl) - ("sqlite" ,sqlite) - ("sh" ,bash-minimal) - ("zlib" ,zlib) - ("zlib:static" ,zlib "static") - ("lz4" ,lz4) - ("lz4:static" ,lz4 "static"))) - (description - "Racket is a general-purpose programming language in the Scheme family, -with a large set of libraries and a compiler based on Chez Scheme. Racket is -also a platform for language-oriented programming, from small domain-specific -languages to complete language implementations. - -The ``minimal Racket'' distribution includes just enough of Racket for you to -use @command{raco pkg} to install more. Bundled packages, such as the -DrRacket IDE, are not included."))) +languages such as Typed Racket, R5RS and R6RS Scheme, Algol 60, and Datalog.")))