Skip to content

Commit

Permalink
Moved Linux ARM64 compilation to native builder
Browse files Browse the repository at this point in the history
- Docker ends up being really slow for cross compilation and we should
  be able to do it as a cross compilation step from x64
  • Loading branch information
daniellockyer committed Dec 30, 2023
1 parent d04c1fb commit b76fb1c
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ jobs:
- x64
target:
- x64
- arm64
node:
- 18
include:
Expand Down Expand Up @@ -82,6 +83,20 @@ jobs:
echo "CFLAGS=${CFLAGS:-} -include ../src/gcc-preinclude.h" >> $GITHUB_ENV
echo "CXXFLAGS=${CXXFLAGS:-} -include ../src/gcc-preinclude.h" >> $GITHUB_ENV
- name: Setup cross compilation for Linux ARM64
if: contains(matrix.os, 'ubuntu') && matrix.target == 'arm64'
run: |
sudo apt-get install -y gcc-aarch64-linux-gnu g++-aarch64-linux-gnu binutils-aarch64-linux-gnu
echo "AS=aarch64-linux-gnu-as" >> $GITHUB_ENV
echo "STRIP=aarch64-linux-gnu-strip" >> $GITHUB_ENV
echo "AR=aarch64-linux-gnu-ar" >> $GITHUB_ENV
echo "CC=aarch64-linux-gnu-gcc" >> $GITHUB_ENV
echo "CPP=aarch64-linux-gnu-cpp" >> $GITHUB_ENV
echo "CXX=aarch64-linux-gnu-g++" >> $GITHUB_ENV
echo "LD=aarch64-linux-gnu-ld" >> $GITHUB_ENV
echo "FC=aarch64-linux-gnu-gfortran" >> $GITHUB_ENV
echo "PKG_CONFIG_PATH=/usr/lib/aarch64-linux-gnu/pkgconfig" >> $GITHUB_ENV
- name: Build binaries
run: yarn prebuild -a ${{ env.TARGET }}

Expand Down Expand Up @@ -120,7 +135,6 @@ jobs:
target:
- linux/arm64
variant:
- bullseye
- alpine3.15
include:
# musl x64 builds
Expand Down

0 comments on commit b76fb1c

Please sign in to comment.