[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
13/15: bootstrap: mes-boot: Scheme-only bootstrap. WIP
From: |
guix-commits |
Subject: |
13/15: bootstrap: mes-boot: Scheme-only bootstrap. WIP |
Date: |
Thu, 10 Jan 2019 17:31:50 -0500 (EST) |
janneke pushed a commit to branch wip-bootstrap
in repository guix.
commit 34bd4329f29f749058007cb1e4a0dad17e79f9e6
Author: Jan Nieuwenhuizen <address@hidden>
Date: Tue Dec 4 23:17:49 2018 +0100
bootstrap: mes-boot: Scheme-only bootstrap. WIP
---
gnu/packages/commencement.scm | 80 ++++++++++++++++++++++++++++++++++++++-----
1 file changed, 72 insertions(+), 8 deletions(-)
diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm
index ca9a426..1916125 100644
--- a/gnu/packages/commencement.scm
+++ b/gnu/packages/commencement.scm
@@ -81,35 +81,76 @@
;;;
;;; Code:
-(define mes-boot
+(define mes-boot0
+ (package
+ (inherit mes)
+ (name "mes-boot0")
+ ;; (source (origin
+ ;; (method url-fetch)
+ ;; (uri (string-append
+ ;; "http://lilypond.org/janneke/mes/"
+ ;; "mes-0.19-20-g5913a812.tar.Z"))
+ ;; (sha256
+ ;; (base32
+ ;; "1n8lp9sx7rwj36dnabn9l8x8y8svb4r47401v3ddgwd2sm9mw6ba"))))
+ (source (origin
+ (method url-fetch)
+ (uri (string-append
+ "http://lilypond.org/janneke/mes/"
+ "mes-0.19-22-g2654869b.tar"))
+ (sha256
+ (base32
+ "0lyn53aynqz98b6nvbgxr61hws27bm06gdqs1qsvy08q9wydlc3s"))))
+ (native-inputs '())
+ (propagated-inputs '())))
+
+(define-public mes-boot
(package-with-bootstrap-guile
(package
- (inherit mes)
+ (inherit mes-boot0)
(name "mes-boot")
(inputs '())
(propagated-inputs '())
(native-inputs
`(("mescc-tools" ,%bootstrap-mescc-tools)
- ("nyacc-source" ,(package-source nyacc))
+ ("nyacc-source" ,(package-source nyacc-boot))
- ("coreutils" , %bootstrap-coreutils&co)
+ ("guile" ,%bootstrap-guile)
+ ("gash" , %bootstrap-gash)
("bootstrap-mes" ,%bootstrap-mes)))
(arguments
`(#:implicit-inputs? #f
+ #:tests? #f
#:guile ,%bootstrap-guile
#:strip-binaries? #f ; binutil's strip b0rkes MesCC/M1/hex2 binaries
#:phases
(modify-phases %standard-phases
+ (add-before 'unpack 'setenv
+ (lambda _
+ (let ((gash (assoc-ref %build-inputs "gash"))
+ (source (assoc-ref %build-inputs "source")))
+ (setenv "PATH" (string-append gash "/libexec/gash:" (getenv
"PATH")))
+ (format #t "PATH=~s\n" (getenv "PATH"))
+ #t)))
(add-after 'unpack 'unpack-seeds
(lambda _
(let ((nyacc-source (assoc-ref %build-inputs "nyacc-source"))
(bootstrap-mes (assoc-ref %build-inputs "bootstrap-mes")))
(with-directory-excursion ".."
(and
- (mkdir-p "nyacc-source")
- (invoke "tar" "--strip=1" "-C" "nyacc-source" "-xvf"
nyacc-source)
+ ;; FIXME: tar --strip broken?
+ ;;(mkdir-p "nyacc-source")
+ ;;(invoke "tar" "--strip=1" "-C" "nyacc-source" "-xvf"
nyacc-source)
+ (invoke "tar" "-xvf" nyacc-source)
+ (rename-file "nyacc-0.86.0" "nyacc-source")
(symlink (string-append bootstrap-mes "/share/mes/lib")
"mes-seed")
#t)))))
+ (add-before 'configure 'remove-bash
+ (lambda _
+ (substitute* "build-aux/check.sh.in"
+ (("(./pre-inst-env bash .*check-boot.sh)" all) (string-append
"# " all))
+ (("(./pre-inst-env sh .*check-mescc.sh)" all) (string-append
"# " all)))
+ #t))
(replace 'configure
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref %outputs "out")))
@@ -121,6 +162,16 @@
(string-append "--prefix=" out)))))
(replace 'build
(lambda _
+ ;; show some progress
+ (substitute* "bootstrap.sh"
+ (("guile build-aux/mes-snarf.scm (.*)" all cmd)
+ (string-append "echo guile -e '(mes-snarf)'
build-aux/mes-snarf.scm " cmd "\n"
+ "guile -e '(mes-snarf)'
build-aux/mes-snarf.scm " cmd "\n"
+ "ls -l src\n"))
+ (("guile (.*)" all cmd)
+ (string-append "echo guile " cmd "\n"
+ "guile " cmd "\n"
+ "ls -l lib lib/x86-mes src\n")))
(let ((mes (assoc-ref %build-inputs "bootstrap-mes")))
(setenv "MES_PREFIX" (string-append mes "/share/mes"))
(setenv "MES_ARENA" "100000000")
@@ -134,11 +185,24 @@
;; fail fast tests
;; (invoke "sh" "-x" "build-aux/test.sh" "scaffold/tests/t")
;; (invoke "sh" "-x" "build-aux/test.sh"
"scaffold/tests/63-struct-cell")
- (setenv "MES_PREFIX" "mes")
+ (setenv "MES_PREFIX" "mes")
(invoke "sh" "check.sh"))))
(replace 'install
(lambda _
- (invoke "sh" "install.sh"))))))
+ (substitute* "install.sh"
+ ((" --exclude=[^ ]*") ""))
+
+ ;; show some progress
+ (substitute* "install.sh"
+ ((" -xf") " -xvf"))
+
+ ;; show some progress
+ (substitute* "install.sh"
+ (("^( *)((cp|mkdir|tar) [^']*[^\\])\n" all space cmd)
+ (string-append space "echo '" cmd "'\n"
+ space cmd "\n")))
+ (format #t "INVOKE\n")
+ (invoke "sh" "-x" "install.sh"))))))
(native-search-paths
;; Use the language-specific variables rather than 'CPATH' because they
;; are equivalent to '-isystem' whereas 'CPATH' is equivalent to '-I'.
- 08/15: Revert "bootstrap: tcc-boot0: Update for mes 0.20. WIP", (continued)
- 08/15: Revert "bootstrap: tcc-boot0: Update for mes 0.20. WIP", guix-commits, 2019/01/10
- 03/15: bootstrap: Update %bootstrap-guile to 2.2., guix-commits, 2019/01/10
- 09/15: bootstrap: %bootstrap-mes: Update for mes 0.20. WIP, guix-commits, 2019/01/10
- 11/15: bootstrap: Add %gash-bootstrap-guile, %gash-bootstrap-guile-tarball., guix-commits, 2019/01/10
- 05/15: gnu: mes: Update to 0.20 WIP, guix-commits, 2019/01/10
- 04/15: bootstrap: Add %bootstrap-gash. WIP, guix-commits, 2019/01/10
- 01/15: gnu: Add gash. WIP, guix-commits, 2019/01/10
- 12/15: pieton: HAK, guix-commits, 2019/01/10
- 06/15: bootstrap: mes-boot: Decouple from mes update. TEMP: avoid build world., guix-commits, 2019/01/10
- 10/15: Revert "bootstrap: mes-boot: Decouple from mes update. TEMP: avoid build world.", guix-commits, 2019/01/10
- 13/15: bootstrap: mes-boot: Scheme-only bootstrap. WIP,
guix-commits <=
- 14/15: bootstrap: tcc-boot0: Scheme-only bootstrap. WIP, guix-commits, 2019/01/10
- 15/15: Scheme-only bootstrap: WIP, guix-commits, 2019/01/10