guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

01/06: chez-sheme-for-racket: Fix building on riscv64-linux.


From: guix-commits
Subject: 01/06: chez-sheme-for-racket: Fix building on riscv64-linux.
Date: Fri, 21 Jul 2023 06:23:06 -0400 (EDT)

efraim pushed a commit to branch master
in repository guix.

commit 261422e7451901d99c6cfcbaa5e0037117588f34
Author: Efraim Flashner <efraim@flashner.co.il>
AuthorDate: Wed Jul 19 21:04:26 2023 +0300

    chez-sheme-for-racket: Fix building on riscv64-linux.
    
    * gnu/packages/racket.scm (%racket-origin): Add patch.
    * gnu/packages/patches/racket-rktboot-riscv64-support.patch: New file.
    * gnu/local.mk (dist_patch_DATA): Register it.
---
 gnu/local.mk                                              |  1 +
 gnu/packages/patches/racket-rktboot-riscv64-support.patch | 15 +++++++++++++++
 gnu/packages/racket.scm                                   |  1 +
 3 files changed, 17 insertions(+)

diff --git a/gnu/local.mk b/gnu/local.mk
index 06a370eec6..76e02a81d5 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1882,6 +1882,7 @@ dist_patch_DATA =                                         
\
   %D%/packages/patches/rpcbind-CVE-2017-8779.patch             \
   %D%/packages/patches/rtags-separate-rct.patch                        \
   %D%/packages/patches/racket-chez-scheme-bin-sh.patch         \
+  %D%/packages/patches/racket-rktboot-riscv64-support.patch    \
   %D%/packages/patches/racket-rktio-bin-sh.patch               \
   %D%/packages/patches/racket-zuo-bin-sh.patch                 \
   %D%/packages/patches/remake-impure-dirs.patch                        \
diff --git a/gnu/packages/patches/racket-rktboot-riscv64-support.patch 
b/gnu/packages/patches/racket-rktboot-riscv64-support.patch
new file mode 100644
index 0000000000..f268b1e7f8
--- /dev/null
+++ b/gnu/packages/patches/racket-rktboot-riscv64-support.patch
@@ -0,0 +1,15 @@
+Submitted upstream:
+https://github.com/racket/racket/pull/4703
+
+diff --git a/racket/src/rktboot/machine-def.rkt 
b/racket/src/rktboot/machine-def.rkt
+index 8ff0688..59ebfc8 100644
+--- a/racket/src/rktboot/machine-def.rkt
++++ b/racket/src/rktboot/machine-def.rkt
+@@ -25,6 +25,7 @@
+                                      [(regexp-match? #rx"^t?arm32" 
target-machine) "arm32"]
+                                      [(regexp-match? #rx"^t?arm64" 
target-machine) "arm64"]
+                                      [(regexp-match? #rx"^t?ppc32" 
target-machine) "ppc32"]
++                                     [(regexp-match? #rx"^t?rv64" 
target-machine) "rv64"]
+                                      [(regexp-match? #rx"^t?pb" 
target-machine) "pb"]
+                                      [else (error "machine.def: cannot infer 
architecture")]))]
+                [s (regexp-replace* #rx"[$][(]Mend[)]" s
diff --git a/gnu/packages/racket.scm b/gnu/packages/racket.scm
index dce7cd9587..03abd7cc41 100644
--- a/gnu/packages/racket.scm
+++ b/gnu/packages/racket.scm
@@ -204,6 +204,7 @@
      (base32 "120djvscm2x1nv46is0kzwahd22rcc8gc0ssf12jnj7w290dpmra"))
     (file-name (git-file-name "racket" %racket-version))
     (patches (search-patches "racket-chez-scheme-bin-sh.patch"
+                             "racket-rktboot-riscv64-support.patch"
                              "racket-rktio-bin-sh.patch"
                              "racket-zuo-bin-sh.patch"))
     (modules '((guix build utils)))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]