@@ -49,24 +49,68 @@ jobs:
49
49
include :
50
50
- os : windows-latest
51
51
target : x86_64-pc-windows-msvc
52
+ build : |
53
+ pnpm build --target x86_64-pc-windows-msvc
54
+
52
55
- os : windows-latest
53
56
target : aarch64-pc-windows-msvc
57
+ build : |
58
+ pnpm build --target aarch64-pc-windows-msvc
59
+
54
60
- os : ubuntu-latest
55
61
target : x86_64-unknown-linux-gnu
62
+ build : |
63
+ pnpm build --target x86_64-unknown-linux-gnu --use-napi-cross
64
+
56
65
- os : ubuntu-latest
57
66
target : x86_64-unknown-linux-musl
67
+ build : |
68
+ pnpm build --target x86_64-unknown-linux-musl -x
69
+
58
70
- os : ubuntu-latest
59
71
target : aarch64-unknown-linux-gnu
72
+ build : |
73
+ pnpm build --target aarch64-unknown-linux-gnu --use-napi-cross
74
+
60
75
- os : ubuntu-latest
61
76
target : aarch64-unknown-linux-musl
77
+ build : |
78
+ pnpm build --target aarch64-unknown-linux-musl -x
79
+
62
80
- os : ubuntu-latest
63
81
target : armv7-unknown-linux-gnueabihf
82
+ build : |
83
+ pnpm build --target armv7-unknown-linux-gnueabihf --use-napi-cross
84
+
64
85
- os : macos-latest
65
86
target : x86_64-apple-darwin
87
+ build : |
88
+ pnpm build --target x86_64-apple-darwin
89
+
66
90
- os : macos-latest
67
91
target : aarch64-apple-darwin
92
+ build : |
93
+ pnpm build --target aarch64-apple-darwin
94
+
68
95
- os : ubuntu-latest
69
96
target : wasm32-wasip1-threads
97
+ build : |
98
+ pnpm build --target wasm32-wasip1-threads
99
+
100
+ - os : ubuntu-latest
101
+ target : s390x-unknown-linux-gnu
102
+ build : |
103
+ export CFLAGS="-fuse-ld=lld"
104
+ pnpm build --target s390x-unknown-linux-gnu --use-napi-cross
105
+
106
+ - os : ubuntu-latest
107
+ target : riscv64gc-unknown-linux-gnu
108
+ build : |
109
+ sudo apt-get update
110
+ sudo apt-get install gcc-riscv64-linux-gnu g++-riscv64-linux-gnu -y
111
+ export CC=riscv64-linux-gnu-gcc
112
+ export CXX=riscv64-linux-gnu-g++
113
+ pnpm build --target riscv64gc-unknown-linux-gnu
70
114
71
115
name : Package ${{ matrix.target }}
72
116
runs-on : ${{ matrix.os }}
@@ -82,25 +126,16 @@ jobs:
82
126
with :
83
127
version : 0.13.0
84
128
85
- - name : Build with zig cross
86
- if : ${{ contains(matrix.target, 'musl') }}
87
- run : pnpm build -x --target ${{ matrix.target }}
88
-
89
- - name : Build with napi cross
90
- if : ${{ contains(matrix.target, 'gnu') }}
91
- env :
92
- CC : clang # for mimalloc
93
- run : pnpm build --use-napi-cross --target ${{ matrix.target }}
94
-
95
129
- name : Build
96
- if : ${{ !contains(matrix.target, 'gnu') && !contains(matrix.target, 'musl') }}
130
+ run : ${{ matrix.build }}
131
+ shell : bash
97
132
env :
98
133
CC : clang # for mimalloc
99
- run : pnpm build --target ${{ matrix.target }}
100
134
101
135
- name : Upload artifacts
102
136
uses : actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
103
137
with :
138
+ if-no-files-found : ' error'
104
139
name : bindings-${{ matrix.target }}
105
140
path : |
106
141
napi/*.node
0 commit comments