fix(release): repair ARM64 package builds (#411)
Define the ARMv8 assembler macro for legacy AArch64 cross-compilers used by the npm and PyPI release matrices, and keep independent targets running when one fails.
This commit is contained in:
@@ -86,12 +86,14 @@ jobs:
|
|||||||
name: Build ${{ matrix.target }}
|
name: Build ${{ matrix.target }}
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
strategy:
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
include:
|
include:
|
||||||
- os: ubuntu-latest
|
- os: ubuntu-latest
|
||||||
target: x86_64-unknown-linux-gnu
|
target: x86_64-unknown-linux-gnu
|
||||||
- os: ubuntu-latest
|
- os: ubuntu-latest
|
||||||
target: aarch64-unknown-linux-gnu
|
target: aarch64-unknown-linux-gnu
|
||||||
|
docker-options: -e CFLAGS_aarch64_unknown_linux_gnu=-D__ARM_ARCH=8
|
||||||
# macos-13 was retired by GitHub; macos-15-intel is the remaining
|
# macos-13 was retired by GitHub; macos-15-intel is the remaining
|
||||||
# Intel runner label (available through 2027).
|
# Intel runner label (available through 2027).
|
||||||
- os: macos-15-intel
|
- os: macos-15-intel
|
||||||
@@ -113,6 +115,9 @@ jobs:
|
|||||||
target: ${{ matrix.target }}
|
target: ${{ matrix.target }}
|
||||||
args: --release --out dist
|
args: --release --out dist
|
||||||
manylinux: auto
|
manylinux: auto
|
||||||
|
# The manylinux AArch64 GCC omits this macro while preprocessing
|
||||||
|
# ring's assembly. AArch64 is ARMv8 by definition.
|
||||||
|
docker-options: ${{ matrix.docker-options }}
|
||||||
|
|
||||||
- name: Upload wheel
|
- name: Upload wheel
|
||||||
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
|
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
|
||||||
|
|||||||
@@ -60,6 +60,7 @@ jobs:
|
|||||||
name: Build ${{ matrix.target }}
|
name: Build ${{ matrix.target }}
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
strategy:
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
include:
|
include:
|
||||||
- os: ubuntu-latest
|
- os: ubuntu-latest
|
||||||
@@ -70,6 +71,7 @@ jobs:
|
|||||||
- os: ubuntu-latest
|
- os: ubuntu-latest
|
||||||
target: aarch64-unknown-linux-gnu
|
target: aarch64-unknown-linux-gnu
|
||||||
build-flags: --use-napi-cross
|
build-flags: --use-napi-cross
|
||||||
|
cflags: -D__ARM_ARCH=8
|
||||||
- os: ubuntu-latest
|
- os: ubuntu-latest
|
||||||
target: x86_64-unknown-linux-musl
|
target: x86_64-unknown-linux-musl
|
||||||
build-flags: -x
|
build-flags: -x
|
||||||
@@ -126,6 +128,10 @@ jobs:
|
|||||||
|
|
||||||
- name: Build native addon
|
- name: Build native addon
|
||||||
working-directory: napi
|
working-directory: napi
|
||||||
|
env:
|
||||||
|
# napi-cross's old AArch64 GCC omits this predefined macro while
|
||||||
|
# preprocessing ring's assembly. AArch64 is ARMv8 by definition.
|
||||||
|
CFLAGS_aarch64_unknown_linux_gnu: ${{ matrix.cflags }}
|
||||||
run: bunx napi build --platform --release --target ${{ matrix.target }} ${{ matrix.build-flags }}
|
run: bunx napi build --platform --release --target ${{ matrix.target }} ${{ matrix.build-flags }}
|
||||||
|
|
||||||
- name: Upload native binary
|
- name: Upload native binary
|
||||||
|
|||||||
Reference in New Issue
Block a user