Skip to content

Commit 070336f

Browse files
committed
ci: fix arm build
Signed-off-by: Yaroslav Bolyukin <iam@lach.pw>
1 parent ec3780b commit 070336f

1 file changed

Lines changed: 10 additions & 6 deletions

File tree

.github/workflows/release.yml

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -126,36 +126,40 @@ jobs:
126126
with:
127127
platform: x86
128128

129+
- name: Musl gcc
130+
if: ${{ endsWith(matrix.target, '-musl') }}
131+
run: sudo apt install musl musl-tools
132+
129133
- name: ARM cross compiler
130-
if: ${{ matrix.target == 'aarch64-unknown-linux-gnu' }}
134+
if: ${{ startsWith(matrix.target, 'aarch64-unknown-linux-') }}
131135
uses: actions-rs/cargo@v1
132136
with:
133137
command: install
134138
args: cross
135139

136140
- name: ARM gcc
137-
if: ${{ matrix.target == 'aarch64-unknown-linux-gnu' }}
141+
if: ${{ startsWith(matrix.target, 'aarch64-unknown-linux-') }}
138142
run: sudo apt install gcc-aarch64-linux-gnu
139143

140144
- name: Run ARM build
141-
if: ${{ matrix.target == 'aarch64-unknown-linux-gnu' }}
145+
if: ${{ startsWith(matrix.target, 'aarch64-unknown-linux-') }}
142146
shell: bash
143147
run: cross build --bin=jrsonnet --release --target ${{ matrix.target }}
144148

145149
- name: Run ARM strip
146-
if: ${{ matrix.target == 'aarch64-unknown-linux-gnu' }}
150+
if: ${{ startsWith(matrix.target, 'aarch64-unknown-linux-') }}
147151
shell: bash
148152
run: aarch64-linux-gnu-strip target/${{ matrix.target }}/release/${{ matrix.bin }}
149153

150154
- name: Run build
151-
if: ${{ matrix.target != 'aarch64-unknown-linux-gnu' }}
155+
if: ${{ !startsWith(matrix.target, 'aarch64-unknown-linux-') }}
152156
uses: actions-rs/cargo@v1
153157
with:
154158
command: build
155159
args: --bin=jrsonnet --release --target ${{ matrix.target }}
156160

157161
- name: Run strip
158-
if: ${{ matrix.target != 'aarch64-unknown-linux-gnu' }}
162+
if: ${{ !startsWith(matrix.target, 'aarch64-unknown-linux-') }}
159163
shell: bash
160164
run: strip target/${{ matrix.target }}/release/${{ matrix.bin }}
161165

0 commit comments

Comments
 (0)