From 17b1b8d930c09bd0f9523e1d2e5c94ac92b8bd0d Mon Sep 17 00:00:00 2001 From: Nico Flaig Date: Fri, 24 Nov 2023 16:17:14 +0100 Subject: [PATCH] Build arm64 binary --- .github/workflows/arm64-binary.yml | 32 ++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 .github/workflows/arm64-binary.yml diff --git a/.github/workflows/arm64-binary.yml b/.github/workflows/arm64-binary.yml new file mode 100644 index 000000000000..b51d352142cf --- /dev/null +++ b/.github/workflows/arm64-binary.yml @@ -0,0 +1,32 @@ +name: Build arm64 binary + +on: push + +jobs: + binary: + name: Build Lodestar arm64 binary + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Set up QEMU + uses: docker/setup-qemu-action@v3 + with: + platforms: arm64 + - name: Set QEMU library path + run: echo "QEMU_LD_PREFIX=/usr/aarch64-linux-gnu" >> $GITHUB_ENV + - name: Install ARM64 libraries + run: sudo apt-get update && sudo apt-get install -y gcc-aarch64-linux-gnu libc6-arm64-cross libc6-dev-arm64-cross + - uses: actions/setup-node@v3 + with: + node-version: 20 + architecture: "arm64" + check-latest: true + - run: | + yarn global add caxa + yarn install --frozen-lockfile --force && yarn build + npm rebuild --update-binary + npx caxa --input . --output "lodestar" -- "{{caxa}}/node_modules/.bin/node" "{{caxa}}/node_modules/.bin/lodestar" + - uses: actions/upload-artifact@v3 + with: + name: lodestar-next-linux-arm64 + path: lodestar