[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
34/42: gnu: Add node-serialport-bindings.
From: |
guix-commits |
Subject: |
34/42: gnu: Add node-serialport-bindings. |
Date: |
Sat, 8 Jan 2022 20:09:38 -0500 (EST) |
lilyp pushed a commit to branch master
in repository guix.
commit d85b3b59a692a21b60f94691a5af985aaf71ec74
Author: Philip McGrath <philip@philipmcgrath.com>
AuthorDate: Sat Jan 8 03:42:22 2022 -0500
gnu: Add node-serialport-bindings.
* gnu/packages/node-xyz.scm (node-serialport-bindings): New variable.
Signed-off-by: Liliana Marie Prikler <liliana.prikler@gmail.com>
---
gnu/packages/node-xyz.scm | 54 +++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 54 insertions(+)
diff --git a/gnu/packages/node-xyz.scm b/gnu/packages/node-xyz.scm
index 206f163bfc..b66aab7c0c 100644
--- a/gnu/packages/node-xyz.scm
+++ b/gnu/packages/node-xyz.scm
@@ -1076,3 +1076,57 @@ recommended high-level interface.
Parsers are used to take raw binary data and transform them into usable
messages. This package provides @code{Readline}, a parser that emits data
after a (configurable) newline delimiter is received.")))
+
+(define-public node-serialport-bindings
+ (package
+ (inherit node-serialport-binding-abstract)
+ (name "node-serialport-bindings")
+ (version "9.2.7")
+ (native-inputs
+ (list python))
+ (inputs
+ (list node-nan node-bindings node-serialport-binding-abstract
+ node-serialport-parser-readline node-debug))
+ (arguments
+ `(#:modules
+ ((guix build node-build-system)
+ (srfi srfi-1)
+ (ice-9 match)
+ (guix build utils))
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'chdir
+ (lambda args
+ (chdir "packages/bindings")))
+ (add-after 'patch-dependencies 'delete-dependencies
+ (lambda args
+ (delete-dependencies `("prebuild-install"
+ ;; devDependencies
+ "@serialport/binding-mock"
+ "node-abi"))))
+ (add-after 'chdir 'avoid-prebuild-install
+ (lambda args
+ (with-atomic-json-file-replacement "package.json"
+ (match-lambda
+ (('@ . pkg-meta-alist)
+ (cons '@ (map (match-lambda
+ (("scripts" @ . scripts-alist)
+ `("scripts" @ ,@(filter (match-lambda
+ (("install" . _)
+ #f)
+ (_
+ #t))
+ scripts-alist)))
+ (other
+ other))
+ pkg-meta-alist))))))))
+ #:tests? #f))
+ (synopsis "Abstract base class for Node SerialPort bindings")
+ (description "Node SerialPort is a modular suite of Node.js packages for
+accessing serial ports. The Guix package @code{node-serialport} provides the
+recommended high-level interface.
+
+This package provides the @code{Binding} class, which uses a native addon to
+talk to the underlying system. You never have to use @code{Binding} objects
+directly. There is also a @code{MockBinding} available (but not yet packaged
+for Guix) to assist with testing.")))
- 18/42: gnu: Add node-inherits., (continued)
- 18/42: gnu: Add node-inherits., guix-commits, 2022/01/08
- 19/42: gnu: Add node-safe-buffer., guix-commits, 2022/01/08
- 20/42: gnu: Add node-string-decoder., guix-commits, 2022/01/08
- 21/42: gnu: Add node-readable-stream., guix-commits, 2022/01/08
- 22/42: gnu: Add node-nan., guix-commits, 2022/01/08
- 23/42: gnu: Add node-openzwave-shared., guix-commits, 2022/01/08
- 30/42: gnu: Add node-debug., guix-commits, 2022/01/08
- 27/42: gnu: Add node-bindings., guix-commits, 2022/01/08
- 33/42: gnu: Add node-serialport-parser-readline., guix-commits, 2022/01/08
- 35/42: gnu: Add node-serialport-parser-regex., guix-commits, 2022/01/08
- 34/42: gnu: Add node-serialport-bindings.,
guix-commits <=
- 39/42: gnu: Add node-serialport-parser-byte-length., guix-commits, 2022/01/08
- 42/42: gnu: node-mersenne: Fix typo in description., guix-commits, 2022/01/08
- 25/42: gnu: Add node-sqlite3., guix-commits, 2022/01/08
- 36/42: gnu: Add node-serialport-parser-ready., guix-commits, 2022/01/08
- 38/42: gnu: Add node-serialport-parser-cctalk., guix-commits, 2022/01/08
- 37/42: gnu: Add node-serialport-parser-inter-byte-timeout., guix-commits, 2022/01/08
- 40/42: gnu: Add node-serialport-stream., guix-commits, 2022/01/08
- 41/42: gnu: Add node-serialport., guix-commits, 2022/01/08