From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id 8GhdKwd082LQTgAAbAwnHQ (envelope-from ) for ; Wed, 10 Aug 2022 11:01:59 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id 2EF5Kwd082I1XwAA9RJhRA (envelope-from ) for ; Wed, 10 Aug 2022 11:01:59 +0200 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 2DA3A15C4C for ; Wed, 10 Aug 2022 11:01:59 +0200 (CEST) Received: from localhost ([::1]:58844 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oLhbC-0007YX-4r for larch@yhetil.org; Wed, 10 Aug 2022 05:01:58 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:49284) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oLhaN-0007Vh-23 for guix-patches@gnu.org; Wed, 10 Aug 2022 05:01:14 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:56282) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oLhaI-0006yv-FL for guix-patches@gnu.org; Wed, 10 Aug 2022 05:01:04 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oLhaI-0008QW-6n for guix-patches@gnu.org; Wed, 10 Aug 2022 05:01:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#57103] [PATCH]: Update sbcl to 2.2.7 Resent-From: =?UTF-8?Q?Andr=C3=A9?= A. Gomes Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 10 Aug 2022 09:01:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 57103 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 57103@debbugs.gnu.org Cc: artyom@atlas.engineer, pierre@atlas.engineer X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.166012203432336 (code B ref -1); Wed, 10 Aug 2022 09:01:02 +0000 Received: (at submit) by debbugs.gnu.org; 10 Aug 2022 09:00:34 +0000 Received: from localhost ([127.0.0.1]:46031 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oLhZo-0008PQ-V0 for submit@debbugs.gnu.org; Wed, 10 Aug 2022 05:00:34 -0400 Received: from lists.gnu.org ([209.51.188.17]:45946) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oLhZl-0008PE-VG for submit@debbugs.gnu.org; Wed, 10 Aug 2022 05:00:31 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:49180) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oLhZg-0007Jw-RM for guix-patches@gnu.org; Wed, 10 Aug 2022 05:00:29 -0400 Received: from mail-lf1-x135.google.com ([2a00:1450:4864:20::135]:35488) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oLhZc-0006vt-29 for guix-patches@gnu.org; Wed, 10 Aug 2022 05:00:23 -0400 Received: by mail-lf1-x135.google.com with SMTP id z25so20367532lfr.2 for ; Wed, 10 Aug 2022 02:00:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:user-agent:message-id:date:subject:cc:to:from:from:to :cc; bh=yEGWeq2V1uni5lMxQAupW8884x+QCjRR3pnR4BBZniU=; b=HogpB4KQGSM84O2WoXQb6fG3OTpo9Qjeff5zE5ym/o7UZKlD3aG2P8AwovQGR/UuGS IEVzX3NAYBdBwi/Knn/CmMKph07KWBu0CpzCqbBVPCsAKCVrh8Kh3TBEogWqiimW1Gn2 +QUfDFVYfz7WC5bvkr+COPKGcf8mHXUIslPlhRw2/fzS9IN71u4cgPo3Wvy6/b8X/szr p4z3U0XQ3Llrb7/dNnS4z4yaTgfk67zyaZ6R/JEaBCdVcG3st90PaRXRZJXHr3iJmCKE BE0jGGXeFBd+eT3V2U2pSkJsvJZOiM/241YyrnIk0o0ZslvTnVKwf6EDj82cmNwb0O6Y fhvg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=mime-version:user-agent:message-id:date:subject:cc:to:from :x-gm-message-state:from:to:cc; bh=yEGWeq2V1uni5lMxQAupW8884x+QCjRR3pnR4BBZniU=; b=vu8Gbsza97TkrhFflEvGrBZOmAqqTozfPejEQnRusOP8lAWf4eICl2fBhb9WbMW02S MS9bIVECzICqVH/j+Au7EO9YkIP8mY2AoprGlyCiWvZNkEvtu7DBvu1fdRUhWOwWxjvj xn2MpmZBXEt+QGacsXY5dd5tUevcY7bYOcw9087wH6kVADb02uSArfSrtPGbqoAesOEm a3FPxwQEVRIdA7twaS6jZBX5a9qnKyL5T8QBzuTqgDpYrrakJeWtXhEdmhUsmDgCehKq JzUVF65SQIzEvNkhm3f+3njTHScwaWn9wVcRNqqRHwIOioT+C4yazbQFJGm3a3+/lMch h6NA== X-Gm-Message-State: ACgBeo3S42i/mLkr1RZ2qKOdIeeWCR2Aj8Yh1VF98EOINCVkrXgQiYgE c8eavJqVpNXi/iuZ7plMIy4= X-Google-Smtp-Source: AA6agR5j4g/vdQLgH0P16rhILkL2opsup0YckrlJYCwgX7c8UkE8Moigiu3si7fUA8p7F1KqqrnqiA== X-Received: by 2002:a05:6512:b96:b0:48b:19c:5332 with SMTP id b22-20020a0565120b9600b0048b019c5332mr10038558lfv.151.1660122016871; Wed, 10 Aug 2022 02:00:16 -0700 (PDT) Received: from guix-xps13 (95-27-199-45.broadband.corbina.ru. [95.27.199.45]) by smtp.gmail.com with ESMTPSA id s14-20020a2e83ce000000b0025e4dcc48b1sm334709ljh.19.2022.08.10.02.00.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 Aug 2022 02:00:16 -0700 (PDT) From: =?UTF-8?Q?Andr=C3=A9?= A. Gomes Date: Wed, 10 Aug 2022 12:00:14 +0300 Message-ID: <87tu6kscbl.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.1.91 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Received-SPF: pass client-ip=2a00:1450:4864:20::135; envelope-from=andremegafone@gmail.com; helo=mail-lf1-x135.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action 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+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1660122119; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:list-id:list-help:list-unsubscribe:list-subscribe: list-post:dkim-signature; bh=yEGWeq2V1uni5lMxQAupW8884x+QCjRR3pnR4BBZniU=; b=H8OWw6JC0T00QiYtzjpoeuuzwJy3uK4zYx9JfHtI7Fcfw9zl7QCOVBvoATD7Yjbok8TwVc jHZEhvqsvYX0OmXB5Brdg+vG5Z24Jkdj9If/ZCEJqsK7F2pBwApWp5lE59qqTvZUzozQR2 NG6GdaE67+Y3ZJHGZywhsRydGRpshZaMhUXGPDRb/KpwbKa1PrVxqZ5fruEONv42wmU5AP 9zwWTaMXbLPb8RIavqSlTYFNrbIcxOB9+bhr8ek9Uv8gxtceSkyleOfg/uRHW8zZx6RIEs 6BwWPTGfZvmpZLSKYOGrFagOcprfw70rUQFxdZn2Da7NMgrbJ6xFPVzFfHbRLQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1660122119; a=rsa-sha256; cv=none; b=jjuDtysKzq136/WOOfVx33hbiQMNkZfzecj7WWSstkNZgf/Vu5j/pA1mCvx2K7xv/pAp9/ K+KOD1tk0KkSFyO8SX22bn97xreq9/2ipkep7YuiI/L9Gi0iof9CXUHFPJgSnF9BHmT3yO ntT9dOqhFEKp/87MjLRw2u7jmc1k+RtQckXSSX4G3FUxx04cVybMpGUhUSZpbFsp0f73LS vIuqFmC1dTlCSI6LjHdhVoT1lsJ0Khp0HVoGh1js3eNMpR8sgMh94eB6gh6JHnpzagrTdB 1o60Vmy2sspXhSGi2ind3QWuKmLQIahznB6UnBaUPaqNncpWH+1ur4j5KbMsnQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=HogpB4KQ; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: 5.91 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=HogpB4KQ; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 2DA3A15C4C X-Spam-Score: 5.91 X-Migadu-Scanner: scn1.migadu.com X-TUID: rJpAsVdLC248 --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hi Guix, The tagged 2.2.7 version of sbcl has some issues. For instance, maxima failed to build. This patch updates sbcl while ensuring that all packages that depend on it build successfully. I tested it by issuing --8<---------------cut here---------------start------------->8--- ./pre-inst-env guix build $(./pre-inst-env guix refresh -l sbcl | cut -d ':= ' -f 2) --8<---------------cut here---------------end--------------->8--- Find the patched attached. Thanks. --=20 Andr=C3=A9 A. Gomes "You cannot even find the ruins..." --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0001-gnu-sbcl-Update-to-2.2.7-0.390809a.patch >From e7687c803d2bb021c4ca89185620383761598303 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20A=2E=20Gomes?= Date: Wed, 10 Aug 2022 11:46:15 +0300 Subject: [PATCH 1/2] gnu: sbcl: Update to 2.2.7-0.390809a. * gnu/packages/lisp.scm (sbcl): Update to 2.2.7-0.390809a. The tagged 2.2.7 version has issues, hence the revision. --- gnu/packages/lisp.scm | 513 +++++++++++++++++++++--------------------- 1 file changed, 260 insertions(+), 253 deletions(-) diff --git a/gnu/packages/lisp.scm b/gnu/packages/lisp.scm index 8e59ec956b..142b800632 100644 --- a/gnu/packages/lisp.scm +++ b/gnu/packages/lisp.scm @@ -411,262 +411,269 @@ (define-public clisp (license license:gpl2+))) (define-public sbcl - (package - (name "sbcl") - (version "2.2.6") - (source - (origin - (method url-fetch) - (uri (string-append "mirror://sourceforge/sbcl/sbcl/" version "/sbcl-" - version "-source.tar.bz2")) - (sha256 - (base32 "18044dqx37mkipnrzs7jrp0cbnwp6snb5gi06a8zn9m8iy6088ry")))) - (build-system gnu-build-system) - (outputs '("out" "doc")) - (native-inputs - ;; From INSTALL: - ;; Supported build hosts are: - ;; SBCL - ;; CMUCL - ;; CCL (formerly known as OpenMCL) - ;; ABCL (recent versions only) - ;; CLISP (only some versions: 2.44.1 is OK, 2.47 is not) - ;; XCL - ;; - ;; From NEWS: - ;; * build enhancement: new host quirks mechanism, support for building under - ;; ABCL and ECL (as well as CCL, CMUCL, CLISP and SBCL itself) - ;; - ;; CCL is not bootstrappable so it won't do. CLISP 2.49 seems to work. - ;; ECL too. As of 2020-07-01, ECL was last updated in 2020 while CLISP - ;; was last updated in 2010, and both take about the same time to build SBCL. - ;; - ;; For now we stick to CLISP as the default for all systems. In any event, keep - ;; the `match' here to make it easier to change the host compiler for various - ;; architectures. Consider switching to ECL if it gets faster than CLISP - ;; (maybe post 2020 release). - (list (match (%current-system) - ("powerpc-linux" ; CLISP fails to build, needs investigating. - ecl) - (_ - clisp)) - cl-asdf - ed - inetutils ;for hostname(1) - texinfo - (texlive-updmap.cfg (list texlive-tex-texinfo)) - which)) - (inputs - (list gmp ; for sb-gmp - mpfr ; for sb-mpfr - (list zstd "lib"))) - (arguments - `(#:modules ((guix build gnu-build-system) - (guix build utils) - (srfi srfi-1)) - #:phases - (modify-phases %standard-phases - ,@(if (target-arm32?) - ;; TODO: Move to snippet in staging. - `((add-after 'unpack 'dont-force-armv5 - (lambda _ - (substitute* "src/runtime/Config.arm-linux" - (("-march=armv5") ""))))) - '()) - (delete 'configure) - (add-after 'unpack 'fix-build-id - ;; One of the build scripts makes a build id using the current date. - ;; Replace it with a reproducible id using a part of the output hash. - (lambda* (#:key outputs #:allow-other-keys) - (let ((hash (substring (assoc-ref outputs "out") - (+ (string-length (%store-directory)) 1) - (+ (string-length (%store-directory)) 9)))) - (substitute* "make-config.sh" - (("echo .* > output/build-id.inc") - (string-append "echo '\"'guix-sbcl-" - hash - "'\"' > output/build-id.inc")))))) - (add-after 'unpack 'replace-asdf - ;; SBCL developers have not committed to keeping ASDF up to date - ;; due to breaking changes [1]. Guix can handle this situation - ;; easily, and it behooves us to have more control over what version - ;; of ASDF we use to build software; therefore, replace the contrib - ;; ASDF with the version packaged into Guix. - ;; [1] - https://bugs.launchpad.net/sbcl/+bug/1823442 - (lambda* (#:key inputs #:allow-other-keys) - (let* ((cl-asdf (assoc-ref inputs "cl-asdf")) - (guix-asdf (string-append - cl-asdf - "/share/common-lisp/source/asdf/asdf.lisp")) - (contrib-asdf "contrib/asdf/asdf.lisp")) - (copy-file guix-asdf contrib-asdf)) - #t)) - (add-before 'build 'patch-unix-tool-paths - (lambda* (#:key outputs inputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (bash (assoc-ref inputs "bash")) - (coreutils (assoc-ref inputs "coreutils")) - (ed (assoc-ref inputs "ed"))) - (define (quoted-path input path) - (string-append "\"" input path "\"")) - ;; Patch absolute paths in string literals. Note that this - ;; occurs in some .sh files too (which contain Lisp code). Use - ;; ISO-8859-1 because some of the files are ISO-8859-1 encoded. - (with-fluids ((%default-port-encoding #f)) - ;; The removed file is utf-16-be encoded, which gives substitute* - ;; trouble. It does not contain references to the listed programs. - (substitute* (delete - "./tests/data/compile-file-pos-utf16be.lisp" - (find-files "." "\\.(lisp|sh)$")) - (("\"/bin/sh\"") (quoted-path bash "/bin/sh")) - (("\"/usr/bin/env\"") (quoted-path coreutils "/usr/bin/env")) - (("\"/bin/cat\"") (quoted-path coreutils "/bin/cat")) - (("\"/bin/ed\"") (quoted-path ed "/bin/ed")) - (("\"/bin/echo\"") (quoted-path coreutils "/bin/echo")) - (("\"/bin/uname\"") (quoted-path coreutils "/bin/uname")))) - ;; This one script has a non-string occurrence of /bin/sh. - (substitute* '("tests/foreign.test.sh") - ;; Leave whitespace so we don't match the shebang. - ((" /bin/sh ") " sh ")) - ;; This file contains a module that can create executable files - ;; which depend on the presence of SBCL. It generates shell - ;; scripts doing "exec sbcl ..." to achieve this. We patch both - ;; the shebang and the reference to "sbcl", tying the generated - ;; executables to the exact SBCL package that generated them. - (substitute* '("contrib/sb-executable/sb-executable.lisp") - (("/bin/sh") (string-append bash "/bin/sh")) - (("exec sbcl") (string-append "exec " out "/bin/sbcl"))) - ;; Disable some tests that fail in our build environment. - (substitute* '("contrib/sb-bsd-sockets/tests.lisp") - ;; This requires /etc/protocols. - (("\\(deftest get-protocol-by-name/error" all) - (string-append "#+nil ;disabled by Guix\n" all))) - (substitute* '("contrib/sb-posix/posix-tests.lisp") - ;; These assume some users/groups which we don't have. - (("\\(deftest pwent\\.[12]" all) - (string-append "#+nil ;disabled by Guix\n" all)) - (("\\(deftest grent\\.[12]" all) - (string-append "#+nil ;disabled by Guix\n" all)))) - #t)) - (add-before 'build 'fix-shared-library-makefile - (lambda _ - (substitute* '("src/runtime/GNUmakefile") - ((" cc") " $(CC)")) - #t)) - (add-before 'build 'fix-contrib-library-path - (lambda* (#:key inputs #:allow-other-keys) - (let ((gmp (assoc-ref inputs "gmp")) - (mpfr (assoc-ref inputs "mpfr"))) - (substitute* '("contrib/sb-gmp/gmp.lisp") - (("\"libgmp\\.so") (string-append "\"" gmp "/lib/libgmp.so"))) - (substitute* '("contrib/sb-mpfr/mpfr.lisp") - (("\"libmpfr\\.so") (string-append "\"" mpfr "/lib/libmpfr.so")))) - #t)) - (replace 'build - (lambda* (#:key outputs #:allow-other-keys) - (setenv "CC" "gcc") - (invoke "sh" "make.sh" ,@(match (%current-system) - ("powerpc-linux" - `("ecl")) - (_ - `("clisp"))) - (string-append "--prefix=" - (assoc-ref outputs "out")) - ,@(if (target-ppc32?) - ;; 3072 is too much for this architecture. - `("--dynamic-space-size=2048") - `("--dynamic-space-size=3072")) - "--with-sb-core-compression" - "--with-sb-xref-for-internals" - ;; SB-SIMD will only be built on x86_64 CPUs supporting - ;; AVX2 instructions. Some x86_64 CPUs don't, so for reproducibility - ;; we disable it and we don't build its documentation (see the - ;; 'build-doc' phase). - "--without-sb-simd"))) - (add-after 'build 'build-shared-library - (lambda* (#:key outputs #:allow-other-keys) - (setenv "CC" "gcc") - (invoke "sh" "make-shared-library.sh"))) - (replace 'install - (lambda _ - (invoke "sh" "install.sh"))) - (add-after 'build 'build-doc - (lambda _ - ;; Don't build the documentation for SB-SIMD as it is disabled in - ;; the 'build' phase. - (substitute* "doc/manual/generate-texinfo.lisp" - (("exclude '\\(\"asdf\"\\)") - "exclude '(\"asdf\" \"sb-simd\")")) - (with-directory-excursion "doc/manual" - (and (invoke "make" "info") - (invoke "make" "dist"))))) - (add-after 'build 'build-source - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (rc (string-append out "/lib/sbcl/sbclrc")) - (source-dir (string-append out "/share/sbcl"))) - (for-each (lambda (p) - (copy-recursively p (string-append source-dir "/" p))) - '("src" "contrib")) - (mkdir-p (dirname rc)) - (with-output-to-file rc - (lambda () - (display - (string-append "(sb-ext:set-sbcl-source-location \"" - source-dir "\")") ))) - #t))) - (add-after 'install 'remove-coreutils-references - ;; They are only useful on non-Linux, non-SBCL. - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (share-dir (string-append out "/share/sbcl/"))) - (substitute* (string-append share-dir "src/code/run-program.lisp") - (("\\(run-program \".*uname\"") - "(run-program \"uname\"")) - (substitute* (string-append share-dir "contrib/asdf/asdf.lisp") - (("\\(\".*/usr/bin/env\"") - "(\"/usr/bin/env\"")) - (substitute* (string-append share-dir "contrib/asdf/uiop.lisp") - (("\\(\".*/usr/bin/env\"") - "(\"/usr/bin/env\"")) - #t))) - (add-after 'install 'install-shared-library - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (lib-dir (string-append out "/lib"))) - (install-file "src/runtime/libsbcl.so" lib-dir) - #t))) - (add-after 'install 'install-doc - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc")) - (old-doc-dir (string-append out "/share/doc")) - (new-doc/sbcl-dir (string-append doc "/share/doc/sbcl"))) - (rmdir (string-append old-doc-dir "/sbcl/html")) - (mkdir-p new-doc/sbcl-dir) - (copy-recursively (string-append old-doc-dir "/sbcl") - new-doc/sbcl-dir) - (delete-file-recursively old-doc-dir) - #t)))) - ;; No 'check' target, though "make.sh" (build phase) runs tests. - #:tests? #f)) - (native-search-paths - (list (search-path-specification - (variable "XDG_DATA_DIRS") - (files '("share"))) - (search-path-specification - (variable "XDG_CONFIG_DIRS") - (files '("etc"))))) - (home-page "http://www.sbcl.org/") - (synopsis "Common Lisp implementation") - (description "Steel Bank Common Lisp (SBCL) is a high performance Common + (let ((commit "390809ae6f32b8dfbf4f5bd3a10425553f0fb7cd") + (revision "0")) + (package + (name "sbcl") + (version (git-version "2.2.7" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference (url "https://git.code.sf.net/p/sbcl/sbcl") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0zlypy366zsk0rm91ad27cmary91xpgrbm7al1f1w5cw03yd6k4l")) + (snippet + '(let ((file (open-file "version.lisp-expr" "w"))) + (display "\"2.2.7\"" file) + (close-port file))))) + (build-system gnu-build-system) + (outputs '("out" "doc")) + (native-inputs + ;; From INSTALL: + ;; Supported build hosts are: + ;; SBCL + ;; CMUCL + ;; CCL (formerly known as OpenMCL) + ;; ABCL (recent versions only) + ;; CLISP (only some versions: 2.44.1 is OK, 2.47 is not) + ;; XCL + ;; + ;; From NEWS: + ;; * build enhancement: new host quirks mechanism, support for building under + ;; ABCL and ECL (as well as CCL, CMUCL, CLISP and SBCL itself) + ;; + ;; CCL is not bootstrappable so it won't do. CLISP 2.49 seems to work. + ;; ECL too. As of 2020-07-01, ECL was last updated in 2020 while CLISP + ;; was last updated in 2010, and both take about the same time to build SBCL. + ;; + ;; For now we stick to CLISP as the default for all systems. In any event, keep + ;; the `match' here to make it easier to change the host compiler for various + ;; architectures. Consider switching to ECL if it gets faster than CLISP + ;; (maybe post 2020 release). + (list (match (%current-system) + ("powerpc-linux" ; CLISP fails to build, needs investigating. + ecl) + (_ + clisp)) + cl-asdf + ed + inetutils ;for hostname(1) + texinfo + (texlive-updmap.cfg (list texlive-tex-texinfo)) + which)) + (inputs + (list gmp ; for sb-gmp + mpfr ; for sb-mpfr + (list zstd "lib"))) + (arguments + `(#:modules ((guix build gnu-build-system) + (guix build utils) + (srfi srfi-1)) + #:phases + (modify-phases %standard-phases + ,@(if (target-arm32?) + ;; TODO: Move to snippet in staging. + `((add-after 'unpack 'dont-force-armv5 + (lambda _ + (substitute* "src/runtime/Config.arm-linux" + (("-march=armv5") ""))))) + '()) + (delete 'configure) + (add-after 'unpack 'fix-build-id + ;; One of the build scripts makes a build id using the current date. + ;; Replace it with a reproducible id using a part of the output hash. + (lambda* (#:key outputs #:allow-other-keys) + (let ((hash (substring (assoc-ref outputs "out") + (+ (string-length (%store-directory)) 1) + (+ (string-length (%store-directory)) 9)))) + (substitute* "make-config.sh" + (("echo .* > output/build-id.inc") + (string-append "echo '\"'guix-sbcl-" + hash + "'\"' > output/build-id.inc")))))) + (add-after 'unpack 'replace-asdf + ;; SBCL developers have not committed to keeping ASDF up to date + ;; due to breaking changes [1]. Guix can handle this situation + ;; easily, and it behooves us to have more control over what version + ;; of ASDF we use to build software; therefore, replace the contrib + ;; ASDF with the version packaged into Guix. + ;; [1] - https://bugs.launchpad.net/sbcl/+bug/1823442 + (lambda* (#:key inputs #:allow-other-keys) + (let* ((cl-asdf (assoc-ref inputs "cl-asdf")) + (guix-asdf (string-append + cl-asdf + "/share/common-lisp/source/asdf/asdf.lisp")) + (contrib-asdf "contrib/asdf/asdf.lisp")) + (copy-file guix-asdf contrib-asdf)) + #t)) + (add-before 'build 'patch-unix-tool-paths + (lambda* (#:key outputs inputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out")) + (bash (assoc-ref inputs "bash")) + (coreutils (assoc-ref inputs "coreutils")) + (ed (assoc-ref inputs "ed"))) + (define (quoted-path input path) + (string-append "\"" input path "\"")) + ;; Patch absolute paths in string literals. Note that this + ;; occurs in some .sh files too (which contain Lisp code). Use + ;; ISO-8859-1 because some of the files are ISO-8859-1 encoded. + (with-fluids ((%default-port-encoding #f)) + ;; The removed file is utf-16-be encoded, which gives substitute* + ;; trouble. It does not contain references to the listed programs. + (substitute* (delete + "./tests/data/compile-file-pos-utf16be.lisp" + (find-files "." "\\.(lisp|sh)$")) + (("\"/bin/sh\"") (quoted-path bash "/bin/sh")) + (("\"/usr/bin/env\"") (quoted-path coreutils "/usr/bin/env")) + (("\"/bin/cat\"") (quoted-path coreutils "/bin/cat")) + (("\"/bin/ed\"") (quoted-path ed "/bin/ed")) + (("\"/bin/echo\"") (quoted-path coreutils "/bin/echo")) + (("\"/bin/uname\"") (quoted-path coreutils "/bin/uname")))) + ;; This one script has a non-string occurrence of /bin/sh. + (substitute* '("tests/foreign.test.sh") + ;; Leave whitespace so we don't match the shebang. + ((" /bin/sh ") " sh ")) + ;; This file contains a module that can create executable files + ;; which depend on the presence of SBCL. It generates shell + ;; scripts doing "exec sbcl ..." to achieve this. We patch both + ;; the shebang and the reference to "sbcl", tying the generated + ;; executables to the exact SBCL package that generated them. + (substitute* '("contrib/sb-executable/sb-executable.lisp") + (("/bin/sh") (string-append bash "/bin/sh")) + (("exec sbcl") (string-append "exec " out "/bin/sbcl"))) + ;; Disable some tests that fail in our build environment. + (substitute* '("contrib/sb-bsd-sockets/tests.lisp") + ;; This requires /etc/protocols. + (("\\(deftest get-protocol-by-name/error" all) + (string-append "#+nil ;disabled by Guix\n" all))) + (substitute* '("contrib/sb-posix/posix-tests.lisp") + ;; These assume some users/groups which we don't have. + (("\\(deftest pwent\\.[12]" all) + (string-append "#+nil ;disabled by Guix\n" all)) + (("\\(deftest grent\\.[12]" all) + (string-append "#+nil ;disabled by Guix\n" all)))) + #t)) + (add-before 'build 'fix-shared-library-makefile + (lambda _ + (substitute* '("src/runtime/GNUmakefile") + ((" cc") " $(CC)")) + #t)) + (add-before 'build 'fix-contrib-library-path + (lambda* (#:key inputs #:allow-other-keys) + (let ((gmp (assoc-ref inputs "gmp")) + (mpfr (assoc-ref inputs "mpfr"))) + (substitute* '("contrib/sb-gmp/gmp.lisp") + (("\"libgmp\\.so") (string-append "\"" gmp "/lib/libgmp.so"))) + (substitute* '("contrib/sb-mpfr/mpfr.lisp") + (("\"libmpfr\\.so") (string-append "\"" mpfr "/lib/libmpfr.so")))) + #t)) + (replace 'build + (lambda* (#:key outputs #:allow-other-keys) + (setenv "CC" "gcc") + (invoke "sh" "make.sh" ,@(match (%current-system) + ("powerpc-linux" + `("ecl")) + (_ + `("clisp"))) + (string-append "--prefix=" + (assoc-ref outputs "out")) + ,@(if (target-ppc32?) + ;; 3072 is too much for this architecture. + `("--dynamic-space-size=2048") + `("--dynamic-space-size=3072")) + "--with-sb-core-compression" + "--with-sb-xref-for-internals" + ;; SB-SIMD will only be built on x86_64 CPUs supporting + ;; AVX2 instructions. Some x86_64 CPUs don't, so for reproducibility + ;; we disable it and we don't build its documentation (see the + ;; 'build-doc' phase). + "--without-sb-simd"))) + (add-after 'build 'build-shared-library + (lambda* (#:key outputs #:allow-other-keys) + (setenv "CC" "gcc") + (invoke "sh" "make-shared-library.sh"))) + (replace 'install + (lambda _ + (invoke "sh" "install.sh"))) + (add-after 'build 'build-doc + (lambda _ + ;; Don't build the documentation for SB-SIMD as it is disabled in + ;; the 'build' phase. + (substitute* "doc/manual/generate-texinfo.lisp" + (("exclude '\\(\"asdf\"\\)") + "exclude '(\"asdf\" \"sb-simd\")")) + (with-directory-excursion "doc/manual" + (and (invoke "make" "info") + (invoke "make" "dist"))))) + (add-after 'build 'build-source + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (rc (string-append out "/lib/sbcl/sbclrc")) + (source-dir (string-append out "/share/sbcl"))) + (for-each (lambda (p) + (copy-recursively p (string-append source-dir "/" p))) + '("src" "contrib")) + (mkdir-p (dirname rc)) + (with-output-to-file rc + (lambda () + (display + (string-append "(sb-ext:set-sbcl-source-location \"" + source-dir "\")") ))) + #t))) + (add-after 'install 'remove-coreutils-references + ;; They are only useful on non-Linux, non-SBCL. + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (share-dir (string-append out "/share/sbcl/"))) + (substitute* (string-append share-dir "src/code/run-program.lisp") + (("\\(run-program \".*uname\"") + "(run-program \"uname\"")) + (substitute* (string-append share-dir "contrib/asdf/asdf.lisp") + (("\\(\".*/usr/bin/env\"") + "(\"/usr/bin/env\"")) + (substitute* (string-append share-dir "contrib/asdf/uiop.lisp") + (("\\(\".*/usr/bin/env\"") + "(\"/usr/bin/env\"")) + #t))) + (add-after 'install 'install-shared-library + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (lib-dir (string-append out "/lib"))) + (install-file "src/runtime/libsbcl.so" lib-dir) + #t))) + (add-after 'install 'install-doc + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (doc (assoc-ref outputs "doc")) + (old-doc-dir (string-append out "/share/doc")) + (new-doc/sbcl-dir (string-append doc "/share/doc/sbcl"))) + (rmdir (string-append old-doc-dir "/sbcl/html")) + (mkdir-p new-doc/sbcl-dir) + (copy-recursively (string-append old-doc-dir "/sbcl") + new-doc/sbcl-dir) + (delete-file-recursively old-doc-dir) + #t)))) + ;; No 'check' target, though "make.sh" (build phase) runs tests. + #:tests? #f)) + (native-search-paths + (list (search-path-specification + (variable "XDG_DATA_DIRS") + (files '("share"))) + (search-path-specification + (variable "XDG_CONFIG_DIRS") + (files '("etc"))))) + (home-page "http://www.sbcl.org/") + (synopsis "Common Lisp implementation") + (description "Steel Bank Common Lisp (SBCL) is a high performance Common Lisp compiler. In addition to the compiler and runtime system for ANSI Common Lisp, it provides an interactive environment including a debugger, a statistical profiler, a code coverage tool, and many other extensions.") - ;; Public domain in jurisdictions that allow it, bsd-2 otherwise. MIT - ;; loop macro has its own license. See COPYING file for further notes. - (license (list license:public-domain license:bsd-2 - (license:x11-style "file://src/code/loop.lisp"))))) + ;; Public domain in jurisdictions that allow it, bsd-2 otherwise. MIT + ;; loop macro has its own license. See COPYING file for further notes. + (license (list license:public-domain license:bsd-2 + (license:x11-style "file://src/code/loop.lisp")))))) (define-public ccl ;; Warning: according to upstream, CCL is not bootstrappable. -- 2.37.1 --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0002-gnu-stumpwm-Update-to-22.05-0.9f47673.patch >From a663ce96fe0a0ce9f5fe2b7c70b14a1ac9ebebac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20A=2E=20Gomes?= Date: Wed, 10 Aug 2022 11:50:26 +0300 Subject: [PATCH 2/2] gnu: stumpwm: Update to 22.05-0.9f47673. * gnu/packages/wm.scm (stumpwm): Update to 22.05-0.9f47673. --- gnu/packages/wm.scm | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/gnu/packages/wm.scm b/gnu/packages/wm.scm index f4dcbf742e..24f6a7ef9c 100644 --- a/gnu/packages/wm.scm +++ b/gnu/packages/wm.scm @@ -1819,23 +1819,24 @@ (define-public kanshi (license license:expat))) ; MIT license (define-public stumpwm - (package + (let ((commit "9f476737d4431d88728738408592bd7004f71255") + (revision "0")) + (package (name "stumpwm") - (version "22.05") + (version (git-version "22.05" revision commit)) (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/stumpwm/stumpwm") - (commit version))) - (file-name (git-file-name "stumpwm" version)) + (commit commit))) + (file-name (git-file-name name version)) (sha256 - (base32 "12hf70mpwy0ixiyvv8sf8pkwrzz8nb12a8ybvsdpibsxfjxgxnan")))) + (base32 "04jifrsp2zs0wvfh87k4xjvndqg4fs4m8ixrlvrilbcl0x01fl36")))) (build-system asdf-build-system/sbcl) (native-inputs (list sbcl-fiasco texinfo - ;; To build the manual. autoconf automake)) @@ -1891,7 +1892,7 @@ (define-public stumpwm productive, customizable lisp based systems.") (home-page "https://github.com/stumpwm/stumpwm") (license license:gpl2+) - (properties `((cl-source-variant . ,(delay cl-stumpwm)))))) + (properties `((cl-source-variant . ,(delay cl-stumpwm))))))) (define-public sbcl-stumpwm (deprecated-package "sbcl-stumpwm" stumpwm)) -- 2.37.1 --=-=-=--