usb 2.0.2 → 2.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # Changelog
2
2
 
3
+ ## [2.0.3] - 2021-12-13
4
+
5
+ ### Added
6
+ - Added definition for `NAPI_VERSION 4` and added N-API v4 target to prebuildify - ([Rob Moran](https://github.com/thegecko))
7
+
3
8
  ## [2.0.2] - 2021-12-12
4
9
 
5
10
  ### Fixed
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "usb",
3
3
  "description": "Library to access USB devices",
4
4
  "license": "MIT",
5
- "version": "2.0.2",
5
+ "version": "2.0.3",
6
6
  "main": "dist/index.js",
7
7
  "engines": {
8
8
  "node": ">=10.16.0"
@@ -46,14 +46,14 @@
46
46
  "full-test": "mocha --require coffeescript/register test/*.coffee",
47
47
  "valgrind": "coffee -c test/*.coffee; valgrind --leak-check=full --show-possibly-lost=no node --expose-gc --trace-gc node_modules/mocha/bin/_mocha -R spec",
48
48
  "docs": "typedoc",
49
- "prebuild": "prebuildify --napi --strip",
50
- "prebuild-darwin": "prebuildify --napi --strip --arch x64+arm64",
51
- "prebuild-win32-x86": "prebuildify --napi --strip",
52
- "prebuild-win32-x64": "prebuildify --napi --strip",
53
- "prebuild-linux-x86": "prebuildify-cross -i ghcr.io/node-usb/linux-x86 --napi --strip",
54
- "prebuild-linux-x64": "prebuildify-cross -i ghcr.io/node-usb/centos7-devtoolset7 -i ghcr.io/node-usb/alpine --napi --strip --tag-libc",
55
- "prebuild-linux-arm": "prebuildify-cross -i ghcr.io/node-usb/linux-arm64 -i ghcr.io/node-usb/linux-armv7 -i ghcr.io/node-usb/linux-armv6 --napi --strip --tag-armv",
56
- "prebuild-android-arm": "prebuildify-cross -i ghcr.io/node-usb/android-arm64 -i ghcr.io/node-usb/android-armv7 --napi --strip --tag-armv",
49
+ "prebuild": "prebuildify --napi --target 10.16.0 --strip",
50
+ "prebuild-darwin": "prebuildify --napi --target 10.16.0 --strip --arch x64+arm64",
51
+ "prebuild-win32-x86": "prebuildify --napi --target 10.16.0 --strip",
52
+ "prebuild-win32-x64": "prebuildify --napi --target 10.16.0 --strip",
53
+ "prebuild-linux-x86": "prebuildify-cross -i ghcr.io/node-usb/linux-x86 --napi --target 10.16.0 --strip",
54
+ "prebuild-linux-x64": "prebuildify-cross -i ghcr.io/node-usb/centos7-devtoolset7 -i ghcr.io/node-usb/alpine --napi --target 10.16.0 --strip --tag-libc",
55
+ "prebuild-linux-arm": "prebuildify-cross -i ghcr.io/node-usb/linux-arm64 -i ghcr.io/node-usb/linux-armv7 -i ghcr.io/node-usb/linux-armv6 --napi --target 10.16.0 --strip --tag-armv",
56
+ "prebuild-android-arm": "prebuildify-cross -i ghcr.io/node-usb/android-arm64 -i ghcr.io/node-usb/android-armv7 --napi --target 10.16.0 --strip --tag-armv",
57
57
  "prebuild-download": "prebuildify-ci download"
58
58
  },
59
59
  "dependencies": {
Binary file
Binary file
Binary file
package/src/node_usb.h CHANGED
@@ -10,6 +10,7 @@
10
10
  #endif
11
11
  #include <libusb.h>
12
12
 
13
+ #define NAPI_VERSION 4
13
14
  #include <napi.h>
14
15
  #include <node_buffer.h>
15
16