From debbugs-submit-bounces@debbugs.gnu.org Tue Mar 30 01:29:06 2021 Received: (at 47282) by debbugs.gnu.org; 30 Mar 2021 05:29:06 +0000 Received: from localhost ([127.0.0.1]:50085 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lR6w5-0005k7-8l for submit@debbugs.gnu.org; Tue, 30 Mar 2021 01:29:05 -0400 Received: from out4-smtp.messagingengine.com ([66.111.4.28]:33529) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lR6vs-0005i7-Dn for 47282@debbugs.gnu.org; Tue, 30 Mar 2021 01:28:52 -0400 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 578365C0178; Tue, 30 Mar 2021 01:28:47 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Tue, 30 Mar 2021 01:28:47 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:date:from :in-reply-to:message-id:mime-version:references:subject:to :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm2; bh=g4k0XFIjNsdRoQDcdxiXmkgmq9PIZuc5UgxwB6n1chw=; b=OVRowGLS Gjvcn9H25uOngyxGqdjhmLeOVcMsTX6n2U7mCD3LMtwfqQHFXn86Rhkfb11l3/Zi 5pB4ymQ3WQ6em5s1EU+2d+fZEyjGIrAQUkTqGwNQBhlmm+EF3ClDnrf3FJGUGrij xT8zC8GeQlsX7n9Ws+UTdo7Uf0Dh27jGycIb9MJshCq6srXp8Sayx4KZTCzsGCBQ m7YptZ1JygtERcxBAHCIbyydbD3poqXaYAzmOOq+X42b6EwMgnZTuy+jHY/ni6oF cbCNE4tffC+4L1wBhc0zoEw6vUbLZlJdAbZRGv35HtqVid3Z1t4c3hr6gmnzGuU5 I4qrtsaw1ZsCJg== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrudehledgleelucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvufffkffojghfggfgsedtkeertdertddtnecuhfhrohhmpefvihhmohht hhihucfurghmphhlvgcuoehsrghmphhlvghtsehnghihrhhordgtohhmqeenucggtffrrg htthgvrhhnpeegvedvteeludehkeejleehjefhvdfhhfetfeeghffhfeekjeetteffkeeh heejkeenucffohhmrghinhepghhithhhuhgsrdgtohhmnecukfhppeejgedrudduiedrud ekiedrgeegnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhho mhepshgrmhhplhgvthesnhhghihrohdrtghomh X-ME-Proxy: Received: from mrblack.lan (74-116-186-44.qc.dsl.ebox.net [74.116.186.44]) by mail.messagingengine.com (Postfix) with ESMTPA id 1DAC724005A; Tue, 30 Mar 2021 01:28:47 -0400 (EDT) From: Timothy Sample To: 47282@debbugs.gnu.org Subject: [PATCH v2 11/13] gnu: Add node-llparse-bootstrap. Date: Tue, 30 Mar 2021 01:27:41 -0400 Message-Id: <20210330052743.575-11-samplet@ngyro.com> X-Mailer: git-send-email 2.31.0 In-Reply-To: <87k0pprz6n.fsf@ngyro.com> References: <87k0pprz6n.fsf@ngyro.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47282 Cc: Jelle Licht X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) From: Jelle Licht * gnu/packages/node.scm (node-llparse-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 16c3decdd4..5336012e43 100644 --- a/gnu/packages/node.scm +++ b/gnu/packages/node.scm @@ -454,6 +454,62 @@ Node.js and web browsers.") (description "This package is a frontend for the llparse compiler.") (license license:expat))) +(define-public node-llparse-bootstrap + (package + (name "node-llparse") + (version "7.1.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/indutny/llparse.git") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "10da273iy2if88hp79cwms6c8qpsl1fkgzll6gmqyx5yxv5mkyp6")) + (modules '((guix build utils))) + (snippet + '(begin + ;; Fix imports for esbuild. + ;; https://github.com/evanw/esbuild/issues/477 + (substitute* '("src/compiler/index.ts" + "src/implementation/c/node/base.ts" + "src/implementation/c/node/table-lookup.ts" + "src/implementation/c/compilation.ts" + "src/implementation/c/helpers/match-sequence.ts" + "src/implementation/c/code/mul-add.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/api.js" + "--bundle" + "src/api.ts"))))))) + (inputs + `(("node-debug" ,node-debug-bootstrap) + ("node-llparse-frontend" ,node-llparse-frontend-bootstrap))) + (native-inputs + `(("esbuild" ,esbuild))) + (home-page "https://github.com/nodejs/llparse#readme") + (properties '((hidden? . #t))) + (synopsis "Compile incremental parsers to C code") + (description "This package offers an API for compiling an incremental +parser definition into a C output.") + (license license:expat))) + (define-public libnode (package/inherit node (name "libnode") -- 2.31.0