[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
10/13: gnu: Add node-llparse-frontend-bootstrap.
From: |
guix-commits |
Subject: |
10/13: gnu: Add node-llparse-frontend-bootstrap. |
Date: |
Fri, 2 Apr 2021 12:06:38 -0400 (EDT) |
jlicht pushed a commit to branch master
in repository guix.
commit 82e7f7c029c36e9e1109ca7f1c191cceca27b278
Author: Jelle Licht <jlicht@fsfe.org>
AuthorDate: Tue Mar 30 01:27:40 2021 -0400
gnu: Add node-llparse-frontend-bootstrap.
* gnu/packages/node.scm (node-llparse-frontend-bootstrap): New variable.
---
gnu/packages/node.scm | 56 +++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 56 insertions(+)
diff --git a/gnu/packages/node.scm b/gnu/packages/node.scm
index 570d452..16c3dec 100644
--- a/gnu/packages/node.scm
+++ b/gnu/packages/node.scm
@@ -398,6 +398,62 @@ Node.js and web browsers.")
(description "This package builds graphs for consumption by llparse.")
(license license:expat)))
+(define-public node-llparse-frontend-bootstrap
+ (package
+ (name "node-llparse-frontend")
+ (version "3.0.0")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/indutny/llparse-frontend.git")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1rm9g4ifyip30svm5cgnf0gx7d45jgh4mpf2hkd092xhngmfvicc"))
+ (modules '((guix build utils)))
+ (snippet
+ '(begin
+ ;; Fix imports for esbuild.
+ ;; https://github.com/evanw/esbuild/issues/477
+ (substitute* '("src/frontend.ts"
+ "src/code/field-value.ts"
+ "src/container/index.ts"
+ "src/container/wrap.ts"
+ "src/node/sequence.ts"
+ "src/node/single.ts"
+ "src/node/table-lookup.ts"
+ "src/trie/index.ts")
+ (("\\* as assert") "assert")
+ (("\\* as debugAPI") "debugAPI"))
+ #t))))
+ (build-system node-build-system)
+ (arguments
+ `(#:node ,node-bootstrap
+ #:tests? #f
+ #:phases
+ (modify-phases %standard-phases
+ (delete 'configure)
+ (replace 'build
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let ((esbuild (string-append (assoc-ref inputs "esbuild")
+ "/bin/esbuild")))
+ (invoke esbuild
+ "--platform=node"
+ "--outfile=lib/frontend.js"
+ "--bundle"
+ "src/frontend.ts")))))))
+ (inputs
+ `(("node-debug" ,node-debug-bootstrap)
+ ("node-llparse-builder" ,node-llparse-builder-bootstrap)))
+ (native-inputs
+ `(("esbuild" ,esbuild)))
+ (home-page "https://github.com/indutny/llparse-frontend#readme")
+ (properties '((hidden? . #t)))
+ (synopsis "Frontend for the llparse compiler")
+ (description "This package is a frontend for the llparse compiler.")
+ (license license:expat)))
+
(define-public libnode
(package/inherit node
(name "libnode")
- branch master updated (532c0e7 -> f6c43c9), guix-commits, 2021/04/02
- 01/13: build-system: Rewrite node build system., guix-commits, 2021/04/02
- 02/13: gnu: Add libuv-for-node, guix-commits, 2021/04/02
- 04/13: gnu: Add node-bootstrap., guix-commits, 2021/04/02
- 13/13: gnu: Add node-lts., guix-commits, 2021/04/02
- 05/13: gnu: Add node-semver-bootstrap., guix-commits, 2021/04/02
- 12/13: gnu: Add llhttp-bootstrap., guix-commits, 2021/04/02
- 11/13: gnu: Add node-llparse-bootstrap., guix-commits, 2021/04/02
- 09/13: gnu: Add node-llparse-builder-bootstrap., guix-commits, 2021/04/02
- 10/13: gnu: Add node-llparse-frontend-bootstrap.,
guix-commits <=
- 08/13: gnu: Add node-debug-bootstrap., guix-commits, 2021/04/02
- 07/13: gnu: Add node-binary-search-bootstrap., guix-commits, 2021/04/02
- 03/13: gnu: node: Use license prefix., guix-commits, 2021/04/02
- 06/13: gnu: Add node-ms-bootstrap., guix-commits, 2021/04/02