@s-h-a-d-o-w/speech-recorder 2.1.10 → 2.1.12

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.
@@ -42,11 +42,11 @@ jobs:
42
42
  with:
43
43
  node-version: lts/*
44
44
 
45
- # - name: Install Linux build dependencies
46
- # if: runner.os == 'Linux'
47
- # run: |
48
- # sudo apt-get update
49
- # sudo apt-get install -y libasound2-dev
45
+ - name: Install Linux build dependencies
46
+ if: runner.os == 'Linux'
47
+ run: |
48
+ sudo apt-get update
49
+ sudo apt-get install -y libasound2-dev
50
50
 
51
51
  - name: Install npm dependencies
52
52
  run: pnpm install --frozen-lockfile --ignore-scripts
package/README.md CHANGED
@@ -2,6 +2,7 @@
2
2
 
3
3
  ## Prerequisites
4
4
 
5
+ - libasound2-dev (Audio backend. Can build without but then the binary won't detect any devices on linux.)
5
6
  - cmake
6
7
 
7
8
  ## Notes
@@ -12,6 +13,7 @@ Prebuilds MUST BE PUBLISHED TO GITHUB using `./build.sh <arch> <GITHUB_TOKEN>`!!
12
13
 
13
14
  Latest portaudio release was in 2021. Which is why it already requires the `-DCMAKE_POLICY_VERSION_MINIMUM=3.5` override and may become incompatible sooner or later.
14
15
 
16
+ `prebuild-install` warns: `deprecated prebuild-install@7.1.3: No longer maintained. Please contact the author of the relevant native addon; alternatives are available.`, yet the recommended `prebuildify` also seems unmaintained and outdated: `https://github.com/prebuild/prebuildify/issues/92` (although... due to semantic versioning, this shouldn't be a problem. User error maybe.).
15
17
 
16
18
  # Speech Recorder
17
19
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@s-h-a-d-o-w/speech-recorder",
3
- "version": "2.1.10",
3
+ "version": "2.1.12",
4
4
  "description": "A node.js library for streaming audio and speech from the microphone.",
5
5
  "main": "src/index.js",
6
6
  "repository": {
package/setup.sh CHANGED
@@ -9,6 +9,15 @@ if [[ -z "$1" ]] ; then
9
9
  exit 1
10
10
  fi
11
11
 
12
+ if [[ `uname -s` == "Linux" ]] ; then
13
+ libasound_status="$(dpkg-query -W -f='${Status}' libasound2-dev 2> /dev/null || true)"
14
+ if [[ "$libasound_status" != "install ok installed" ]] ; then
15
+ echo "Missing required package: libasound2-dev"
16
+ echo "Install it with: sudo apt install libasound2-dev"
17
+ exit 1
18
+ fi
19
+ fi
20
+
12
21
  rm -rf tmp lib/3rd_party/portaudio lib/3rd_party/onnxruntime
13
22
 
14
23
  mkdir -p tmp/portaudio