[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
58/160: gnu: mes-boot: Update to 0.15.
From: |
Jan Nieuwenhuizen |
Subject: |
58/160: gnu: mes-boot: Update to 0.15. |
Date: |
Tue, 28 Aug 2018 15:56:16 -0400 (EDT) |
janneke pushed a commit to branch wip-bootstrap
in repository guix.
commit f5448ed530d186cb6a669ddadcca919d3ca2887d
Author: Jan Nieuwenhuizen <address@hidden>
Date: Mon May 28 19:12:13 2018 +0200
gnu: mes-boot: Update to 0.15.
* gnu/packages/mes.scm (%fake-bootstrap?): New variable.
(mes-boot): If %fake-bootstrap, cheat using Guile to build in ~1min.
Update to 0.15.
---
gnu/packages/mes.scm | 81 ++++++++++++++++++++++++++++++----------------------
1 file changed, 47 insertions(+), 34 deletions(-)
diff --git a/gnu/packages/mes.scm b/gnu/packages/mes.scm
index f4a496b..2988b7f 100644
--- a/gnu/packages/mes.scm
+++ b/gnu/packages/mes.scm
@@ -39,6 +39,8 @@
#:use-module (guix licenses)
#:use-module (guix packages))
+(define %fake-bootstrap? #f) ; cheat using Guile instead of Mes for speed-up?
+
(define %mescc-tools-seed
(let ((commit"32881b9ff21fb41dc846914753b6cdadd75927c4"))
(origin
@@ -223,9 +225,9 @@ hex2 linker.")
(license gpl3+)))))
(define-public mes-boot
- (let ((version "0.14")
+ (let ((version "0.15")
(revision "0")
- (commit "4e50490aa2513ced5b568f434b23ba36218ba7b3"))
+ (commit "04a4a8dd9fbf4c049cfc284012d718e2d4fdbbbe"))
(package-with-bootstrap-guile
(package
(name "mes-boot")
@@ -238,21 +240,21 @@ hex2 linker.")
"/mes-" commit ".tar.gz"))
(sha256
(base32
- "0ydsmkqb0sm1rhh83r0kyqv7664iw1ginvd52gp11mx7317qaldk"))))
+ "1c7h1nlv8glnkaxlavf2z0c93d9whxf82ifvfap3jdr7jjjmy2np"))))
(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)))
- ;; For testing with Guile
- ;; ("guile" ,%bootstrap-guile)
- ;; guile-2.0.9 does not have srfi-43; cherry-pick
- ("srfi-43" ,%srfi-43)
("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" ,%mes-seed)))
+ ("mes-seed" ,%mes-seed)
+ ,@(if %fake-bootstrap? ; cheat: fast non-bootstrap testing with Guile
+ `(("guile" ,%bootstrap-guile)
+ ("srfi-43" ,%srfi-43)) ; guile-2.0.9 lacks srfi-43;
cherry-pick
+ '())))
(arguments
`(#:modules ((guix build utils))
#:builder
@@ -269,6 +271,8 @@ hex2 linker.")
(mes-seed (assoc-ref %build-inputs "mes-seed"))
(out (assoc-ref %outputs "out"))
(dir (getcwd)))
+
+ ;; unpack
(setenv "PATH" (string-append
bash "/bin:"
(if guile (string-append guile "/bin:") "")
@@ -282,43 +286,52 @@ hex2 linker.")
(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")
+ (when srfi-43
+ (mkdir-p "srfi")
+ (system* "cp" srfi-43 "srfi/srfi-43.scm"))
(chdir "source")
;; configure
(setenv "PREFIX" out)
- (when guile
- (setenv "GUILE_AUTO_COMPILE" "1")
- (setenv "GUILE_LOAD_COMPILED_PATH"
- (string-append guile "/lib/guile/2.0/ccache"))
- (setenv "GUILE_LOAD_PATH"
- (string-append "../nyacc-source/module"
- ":" dir
- ":" guile "/share/guile/2.0/")))
-
- ;; guile-2.0 fails
- (delete-file "tests/srfi-43.test-guile")
-
- ;; give auto-compile a home -- massive speed-up
- (mkdir-p "/tmp/home")
- (setenv "HOME" "/tmp/home")
-
- (when (not guile)
- (symlink (string-append "../nyacc-source/module") "nyacc")
- (setenv "GUILE_LOAD_PATH" "nyacc")
- (setenv "MES" "src/mes")
- (setenv "GUILE" "true"))
+
+ ;; (setenv "BUILD_DEBUG" "1")
+ (if ,%fake-bootstrap?
+ (begin ; Cheat using Guile+Nyacc+MesCC; ~30 times faster
+ (setenv "MES" "guile")
+ (setenv "GUILE_AUTO_COMPILE" "1")
+ (setenv "GUILE_LOAD_COMPILED_PATH"
+ (string-append guile "/lib/guile/2.0/ccache"))
+ (setenv "GUILE_LOAD_PATH"
+ (string-append (string-append dir
"/nyacc-source/module")
+ ":" dir
+ ":" guile "/share/guile/2.0/"))
+ ;; these fail with guile-2.0
+ (when srfi-43
+ (delete-file "tests/srfi-9.test-guile")
+ (delete-file "tests/srfi-43.test-guile"))
+
+ ;; give auto-compile a home -- massive speed-up
+ (mkdir-p "/tmp/home")
+ (setenv "HOME" "/tmp/home"))
+
+ (begin ; True bootstrap build Mes+Nyacc+MesCC
+ (symlink (string-append "../nyacc-source/module") "nyacc")
+ (setenv "GUILE_LOAD_PATH" "nyacc")
+ (setenv "MES" "src/mes")))
+
+ (setenv "GUILE_TOOLS" "true") ; no tools in bootstrap-guile
(setenv "MESCC" "scripts/mescc")
(setenv "MES_MODULEDIR" "module")
+
(and
;; build
(zero? (system* "sh" "build.sh"))
;; check
- (zero? (system* "sh" "-x" "build-aux/test.sh"))
- (zero? (system* "sh" "-x" "build-aux/test.sh"
"scaffold/tests/63-struct-cell"))
- (zero? (system* "sh" "check.sh"))
+ (unless ,%fake-bootstrap? ; check takes ~15min, skip when faking
+ (zero? (system* "sh" "build-aux/test.sh"))
+ (zero? (system* "sh" "build-aux/test.sh"
"scaffold/tests/63-struct-cell"))
+ (zero? (system* "sh" "check.sh")))
;; install
(setenv "SHELL" (string-append bash "/bin/bash"))
- 104/160: gnu: gcc-mesboot: Rename from gcc-boot., (continued)
- 104/160: gnu: gcc-mesboot: Rename from gcc-boot., Jan Nieuwenhuizen, 2018/08/28
- 109/160: REMOVEME: %fake-bootstrap => #t., Jan Nieuwenhuizen, 2018/08/28
- 108/160: gnu: Add gcc-mesboot 4.7.4. WIP, Jan Nieuwenhuizen, 2018/08/28
- 91/160: gnu: gcc-core-boot: Install libgcc2.a too., Jan Nieuwenhuizen, 2018/08/28
- 106/160: Revert: gnu: binutils-boot0: Inject AR, LD from bootstrap-binaries., Jan Nieuwenhuizen, 2018/08/28
- 111/160: gnu: m4-mesboot: Package with boostrap-guile., Jan Nieuwenhuizen, 2018/08/28
- 102/160: gnu: gcc-core-mesboot: Rename from gcc-core-boot., Jan Nieuwenhuizen, 2018/08/28
- 98/160: gnu: binutils-boot0: Inject AR, LD from bootstrap-binaries., Jan Nieuwenhuizen, 2018/08/28
- 86/160: gnu: mes-boot: Update for fopen: Return 0 upon failure., Jan Nieuwenhuizen, 2018/08/28
- 96/160: gnu: Add binutils-boot0-cheat., Jan Nieuwenhuizen, 2018/08/28
- 58/160: gnu: mes-boot: Update to 0.15.,
Jan Nieuwenhuizen <=
- 88/160: gnu: mes-boot: Update to 0.16., Jan Nieuwenhuizen, 2018/08/28
- 85/160: gnu: mes-boot: Update for linux-4.17 elf32-header fix., Jan Nieuwenhuizen, 2018/08/28
- 100/160: gnu: m4:mesboot: Rename from m4-boot., Jan Nieuwenhuizen, 2018/08/28
- 93/160: gnu: Add tcc-boot 0.9.27., Jan Nieuwenhuizen, 2018/08/28
- 87/160: gnu: %mes-seed: Update for mes 0.16., Jan Nieuwenhuizen, 2018/08/28
- 92/160: gnu: Add binutils-boot 2.20.1, built with gcc+glibc., Jan Nieuwenhuizen, 2018/08/28
- 89/160: gnu: %tinycc-seed: Update for mes 0.16., Jan Nieuwenhuizen, 2018/08/28
- 76/160: Revert "gnu: gcc-boot: Update to 3.2.", Jan Nieuwenhuizen, 2018/08/28
- 82/160: Revert "REMOVEME: %fake-bootstrap => #t.", Jan Nieuwenhuizen, 2018/08/28
- 64/160: gnu: binutils-boot: Update to 2.14., Jan Nieuwenhuizen, 2018/08/28