@@ -2,13 +2,42 @@ name: prebuild
2
2
on : [push]
3
3
4
4
jobs :
5
+ linux-package :
6
+ runs-on : ubuntu-latest
7
+ container :
8
+ image : node:16.20.2-bookworm-slim
9
+ steps :
10
+ - uses : actions/checkout@v2
11
+ with :
12
+ lfs : true
13
+
14
+ - name : install Linux dependencies
15
+ run : |
16
+ apt-get update
17
+ apt-get install -y build-essential pkg-config libtool python3 python-is-python3
18
+ apt-get install -y libavcodec-dev libavformat-dev libavdevice-dev libavfilter-dev libavutil-dev libpostproc-dev libswresample-dev libswscale-dev libzimg-dev
19
+
20
+ - name : npm install
21
+ run : npm install
22
+ env :
23
+ PREBUILD : true
24
+
25
+
26
+ - name : check Linux dependencies
27
+ run : node ./install_ffmpeg.js
28
+
29
+ - name : prebuild for Linux (x64)
30
+ run : npx prebuild --runtime napi --arch x64 --include-regex '(\.node|\.dylib|ffmpeg|ffprobe)$' --upload ${{ secrets.GITHUB_TOKEN }}
31
+
32
+ - name : prebuild for Linux (arm64)
33
+ run : npx prebuild --runtime napi --arch arm64 --include-regex '(\.node|\.dylib|ffmpeg|ffprobe)$' --upload ${{ secrets.GITHUB_TOKEN }}
34
+
5
35
package :
6
36
runs-on : ${{ matrix.os }}
7
37
strategy :
8
38
fail-fast : false
9
39
matrix :
10
40
os :
11
- - ubuntu-22.04
12
41
- macos-latest
13
42
- windows-latest
14
43
steps :
26
55
env :
27
56
PREBUILD : true
28
57
29
- - name : install Linux dependencies
30
- run : |
31
- sudo add-apt-repository ppa:savoury1/ffmpeg5
32
- sudo apt-get update
33
- sudo apt-get install -y libavcodec-dev libavformat-dev libavdevice-dev libavfilter-dev libavutil-dev libpostproc-dev libswresample-dev libswscale-dev libzimg-dev
34
- if : ${{ runner.os == 'Linux' }}
35
-
36
- - name : check Linux dependencies
37
- run : node ./install_ffmpeg.js
38
- if : ${{ runner.os == 'Linux'}}
39
-
40
58
- name : install Mac build dependencies (brew)
41
59
run : brew install nasm pkg-config
42
60
if : ${{ runner.os == 'macOS'}}
73
91
run : npx prebuild --runtime napi --include-regex '.node|.dll|.exe' --verbose --upload ${{ secrets.GITHUB_TOKEN }}
74
92
shell : bash
75
93
if : ${{ runner.os == 'Windows'}}
76
-
77
- - name : prebuild for Linux (x64)
78
- run : npx prebuild --runtime napi --arch x64 --include-regex '(\.node|\.dylib|ffmpeg|ffprobe)$' --upload ${{ secrets.GITHUB_TOKEN }}
79
- if : ${{ runner.os == 'Linux'}}
80
-
81
- - name : prebuild for Linux (arm64)
82
- run : npx prebuild --runtime napi --arch arm64 --include-regex '(\.node|\.dylib|ffmpeg|ffprobe)$' --upload ${{ secrets.GITHUB_TOKEN }}
83
- if : ${{ runner.os == 'Linux'}}
0 commit comments