[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
19/207: gnu: mes-boot: Use bootstrap Guile and simplify.
From: |
Jan Nieuwenhuizen |
Subject: |
19/207: gnu: mes-boot: Use bootstrap Guile and simplify. |
Date: |
Sat, 8 Sep 2018 13:25:54 -0400 (EDT) |
janneke pushed a commit to branch wip-bootstrap
in repository guix.
commit 267fef4829538ff01046cb8389fdf12b54ae87cb
Author: Jan Nieuwenhuizen <address@hidden>
Date: Sun Nov 26 19:34:46 2017 +0100
gnu: mes-boot: Use bootstrap Guile and simplify.
* gnu/packages/mes.scm (mes-boot): Simplify; use %bootstrap-guile and
package-with-bootstrap-guile.
---
gnu/packages/mes.scm | 165 +++++++++++++++++++++++++++------------------------
1 file changed, 88 insertions(+), 77 deletions(-)
diff --git a/gnu/packages/mes.scm b/gnu/packages/mes.scm
index 78aee2d..e0e0aee 100644
--- a/gnu/packages/mes.scm
+++ b/gnu/packages/mes.scm
@@ -205,93 +205,104 @@ hex2 linker.")
(license gpl3+)))))
(define-public mes-boot
- (let ((version "0.11")
+ (let ((version "0.11")
(revision "0")
- (commit "a3d445e9049f6b6603d8c69c0e33bd071cf15b1c"))
- (package
- (name "mes-boot")
- (version (string-append version "-" revision "." (string-take commit 7)))
- (synopsis "Scheme interpreter and C compiler for full source
bootstrapping")
- (source (origin
+ (commit "234ab121478ef4c59c1cedbf9e361a64b4e954d2"))
+ (package-with-bootstrap-guile
+ (package
+ (name "mes-boot")
+ (version (string-append version "-" revision "." (string-take commit
7)))
+ (synopsis "Scheme interpreter and C compiler for full source
bootstrapping")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "https://gitlab.com/janneke/mes"
+ "/repository/archive.tar.gz?ref="
+ commit))
+ (file-name (string-append name "-" version ".tar.xz"))
+ (sha256
+ (base32
+ "0jxrnv2fgi4n3hvq48li8l21439hmhm83ifdxhfsjggyf2kka3d0"))))
+ (build-system trivial-build-system)
+ (supported-systems '("i686-linux" "x86_64-linux"))
+ (native-inputs
+ `(("static-bash" ,@(assoc-ref %bootstrap-inputs "bash"))
+ ("bash" ,(search-bootstrap-binary "bash" (%current-system)))
+ ("guile" ,%bootstrap-guile)
+ ;; guile-2.0.9 does not have srfi-43; cherry-pick
+ ("srfi-43" ,(origin
+ (method url-fetch)
+ (uri
"http://git.savannah.gnu.org/cgit/guile.git/plain/module/srfi/srfi-43.scm?h=stable-2.0")
+ (file-name "srfi-43.scm")
+ (sha256
+ (base32
+
"0rnkppwdkxbzkgp9s9ccmby9f7p3ijxjlmvj0pzqxwmrmpy7jwmb"))))
+ ("tar" ,(search-bootstrap-binary "tar" (%current-system)))
+ ("xz" ,(search-bootstrap-binary "xz" (%current-system)))
+ ("mescc-tools" ,mescc-tools-boot)
+ ("nyacc-source" ,(package-source nyacc-boot))
+ ("mes-seed"
+ ,(origin
(method url-fetch)
- (uri (string-append "https://gitlab.com/janneke/mes"
+ (uri (string-append "https://gitlab.com/janneke/mes-seed"
"/repository/archive.tar.gz?ref="
- commit))
- (file-name (string-append name "-" version ".tar.xz"))
+ "fe64ff3a855d20bc90a5f28237e9832d33731b91"))
+ (file-name (string-append "mes-seed-0.11" ".tar.xz"))
(sha256
(base32
- "0ss7qrzavl3m33naq3v1qawzd8nniwa84cm7kqkkv5n5l6rawxjw"))))
- (build-system trivial-build-system)
- (supported-systems '("i686-linux" "x86_64-linux"))
- (native-inputs
- `(("static-bash" ,@(assoc-ref %bootstrap-inputs "bash"))
- ("bash" ,(search-bootstrap-binary "bash" (%current-system)))
- ("tar" ,(search-bootstrap-binary "tar" (%current-system)))
- ("xz" ,(search-bootstrap-binary "xz" (%current-system)))
- ("mescc-tools" ,mescc-tools-boot)
- ("nyacc-source" ,(package-source nyacc))
- ("mes-seed"
- ,(origin
- (method url-fetch)
- (uri (string-append "https://gitlab.com/janneke/mes-seed"
- "/repository/archive.tar.gz?ref="
- "fe64ff3a855d20bc90a5f28237e9832d33731b91"))
- (file-name (string-append "mes-seed-0.11" ".tar.xz"))
- (sha256
- (base32
- "0ggc7r5mla44ilaxxj4x1z0k757i9h5ymd54l7wvjw7883z3ag5j"))))))
- (arguments
- `(#:modules ((guix build utils))
- #:builder
- (begin
- (use-modules (guix build utils))
- (let* ((bash (assoc-ref %build-inputs "static-bash"))
- (mescc-tools (assoc-ref %build-inputs "mescc-tools"))
- (tar (assoc-ref %build-inputs "tar"))
- (xz (assoc-ref %build-inputs "xz"))
- (source (assoc-ref %build-inputs "source"))
- (nyacc-source (assoc-ref %build-inputs "nyacc-source"))
- (mes-seed (assoc-ref %build-inputs "mes-seed"))
- (out (assoc-ref %outputs "out"))
- (out/bin (string-append out "/bin"))
- (dir (getcwd)))
- (setenv "PATH" (string-append bash "/bin:"
- mescc-tools "/bin:"
- tar "/bin:"
- xz "/bin"))
- (format (current-error-port) "PATH=~s\n" (getenv "PATH"))
- (mkdir-p "source")
- (system* "tar" "--strip=1" "-C" "source" "-xvf" source)
- (mkdir-p "nyacc-source")
- (system* "tar" "--strip=1" "-C" "nyacc-source" "-xvf" nyacc-source)
- (mkdir-p "mes-seed")
- (system* "tar" "--strip=1" "-C" "mes-seed" "-xvf" mes-seed)
- (chdir "source")
- (zero? (system (string-append
-"set -ex;"
-
-"export PREFIX=" out ";"
-
-;; build
-"sh build.sh;"
-
-;; check
-"export GUILE=true;"
-"export GUILE_LOAD_PATH=" dir
- ":" dir "/nyacc-source/module"
- ":" dir "/guile;"
-"sh check.sh;"
-
-;; install
-"unset GUILE;"
-"sh install.sh;"))))))) ; []
- (description
+ "0ggc7r5mla44ilaxxj4x1z0k757i9h5ymd54l7wvjw7883z3ag5j"))))))
+ (arguments
+ `(#:modules ((guix build utils))
+ #:builder
+ (begin
+ (use-modules (guix build utils))
+ (let* ((bash (assoc-ref %build-inputs "static-bash"))
+ (guile (assoc-ref %build-inputs "guile"))
+ (srfi-43 (assoc-ref %build-inputs "srfi-43"))
+ (mescc-tools (assoc-ref %build-inputs "mescc-tools"))
+ (tar (assoc-ref %build-inputs "tar"))
+ (xz (assoc-ref %build-inputs "xz"))
+ (source (assoc-ref %build-inputs "source"))
+ (nyacc-source (assoc-ref %build-inputs "nyacc-source"))
+ (mes-seed (assoc-ref %build-inputs "mes-seed"))
+ (out (assoc-ref %outputs "out"))
+ (dir (getcwd)))
+ (setenv "PATH" (string-append bash "/bin:"
+ guile "/bin:"
+ mescc-tools "/bin:"
+ tar "/bin:"
+ xz "/bin"))
+ (format (current-error-port) "PATH=~s\n" (getenv "PATH"))
+ (mkdir-p "source")
+ (system* "tar" "--strip=1" "-C" "source" "-xvf" source)
+ (mkdir-p "nyacc-source")
+ (system* "tar" "--strip=1" "-C" "nyacc-source" "-xvf"
nyacc-source)
+ (mkdir-p "mes-seed")
+ (system* "tar" "--strip=1" "-C" "mes-seed" "-xvf" mes-seed)
+ (mkdir-p "srfi")
+ (system* "cp" srfi-43 "srfi/srfi-43.scm")
+ (chdir "source")
+ (setenv "PREFIX" out)
+ (setenv "GUILE_AUTO_COMPILE" "1")
+ (setenv "GUILE_LOAD_COMPILED_PATH"
+ (string-append guile "/lib/guile/2.0/ccache"))
+ (setenv "GUILE_LOAD_PATH"
+ (string-append dir
+ ":" guile "/share/guile/2.0/"
+ ":" dir "/nyacc-source/module"))
+ ;; give auto-compile a home -- massive speed-up
+ (mkdir-p "/tmp/home")
+ (setenv "HOME" "/tmp/home")
+ (and
+ (zero? (system* "sh" "build.sh"))
+ (zero? (system* "sh" "check.sh"))
+ (zero? (system* "sh" "install.sh")))))))
+ (description
"Mes [Maxwell Equations of Software] aims to create full source
bootstrapping for GuixSD. It consists of a mutual self-hosting [close to
Guile-] Scheme interpreter prototype in C and a Nyacc-based C compiler in
[Guile] Scheme.") ; []
(home-page "https://gitlab.com/janneke/mes")
- (license gpl3+))))
+ (license gpl3+)))))
(define-public nyacc-boot
(let ((version "0.82.4")
- 39/207: gnu: %tinycc-seed: Update for mes-0.12., (continued)
- 39/207: gnu: %tinycc-seed: Update for mes-0.12., Jan Nieuwenhuizen, 2018/09/08
- 31/207: gnu: Update tcc-boot: mescc char cast truncate bug., Jan Nieuwenhuizen, 2018/09/08
- 33/207: gnu: Update mes-boot: Add qsort., Jan Nieuwenhuizen, 2018/09/08
- 38/207: gnu: mes-boot: Update to 0.12., Jan Nieuwenhuizen, 2018/09/08
- 42/207: gnu: mescc-tools-boot: Remove stage0 dependency., Jan Nieuwenhuizen, 2018/09/08
- 30/207: gnu: Update tcc-boot: mescc has no long long., Jan Nieuwenhuizen, 2018/09/08
- 34/207: gnu: Update tcc-boot: qsort., Jan Nieuwenhuizen, 2018/09/08
- 35/207: gnu: Update mes-boot: M4 support: robustify headers., Jan Nieuwenhuizen, 2018/09/08
- 24/207: gnu: Update mescc-tools-boot, mes-boot, tcc-boot for blood-elf., Jan Nieuwenhuizen, 2018/09/08
- 20/207: gnu: mes-boot: Update mes-boot, mes-seed: Mescc-tools support., Jan Nieuwenhuizen, 2018/09/08
- 19/207: gnu: mes-boot: Use bootstrap Guile and simplify.,
Jan Nieuwenhuizen <=
- 23/207: gnu: mescc-tools-boot: Update to bootstrap from M1 binaries., Jan Nieuwenhuizen, 2018/09/08
- 15/207: gnu: tcc-boot: Use bootstrap Guile and simplify., Jan Nieuwenhuizen, 2018/09/08
- 21/207: gnu: Update mes-boot: Mescc-tools support: char foo[BAR] = {'a', 'b', 'c'}., Jan Nieuwenhuizen, 2018/09/08
- 22/207: gnu: Update mescc-tools-boot: bootstrap from .M1 sources: remove MORTAL SIN., Jan Nieuwenhuizen, 2018/09/08
- 17/207: bump: mlibc: Mescc-tools support: chmod., Jan Nieuwenhuizen, 2018/09/08
- 12/207: bump mes-boot: mlibc: GNU Gcc support: setjmp, longjmp., Jan Nieuwenhuizen, 2018/09/08
- 14/207: bump tcc-boot: mlibc: GNU Gcc support: setjmp, longjmp., Jan Nieuwenhuizen, 2018/09/08
- 10/207: bump: mes-tools: add ferror for [m4] configure, Jan Nieuwenhuizen, 2018/09/08
- 04/207: gnu: Add nyacc-boot., Jan Nieuwenhuizen, 2018/09/08
- 26/207: gnu: Update mescc-tools-boot, mes-boot, tcc-boot., Jan Nieuwenhuizen, 2018/09/08