Skip to content

Add macOS build support #49

Add macOS build support

Add macOS build support #49

Workflow file for this run

name: CI-build-arm64
on:
pull_request:
branches: [ "master" ]
push:
branches:
- master
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
if: ${{ github.event_name != 'pull_request' || (github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'notest') != true) }}
strategy:
fail-fast: false
matrix:
build_mode: [Release, RelWithDebInfo, Debug]
cxx11: [ON, OFF]
runs-on: ubuntu-latest
name: Build arm64 ubuntu 22.04 BUILD_MODE=${{ matrix.build_mode }}, CXX11=${{ matrix.cxx11 }}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Ubuntu
run: |
sudo apt install gcc-aarch64-linux-gnu g++-aarch64-linux-gnu qemu-user-static debootstrap
- name: Build
run: |
export ROOTFS=${GITHUB_WORKSPACE}/rootfs/arm64
sudo ./create-ubuntu-rootfs.sh arm64 jammy
TOOLCHAIN_VER=$(ls $ROOTFS/usr/include/c++/)
sed -i "s,set(TOOLCHAIN_VERSION \"7\"),set(TOOLCHAIN_VERSION \"$TOOLCHAIN_VER\")," arm64-gcc-toolchain.cmake
./Tools/test-build.sh ${GITHUB_WORKSPACE} ${GITHUB_WORKSPACE}/Build "aarch64-linux-gnu-gcc,aarch64-linux-gnu-g++" ${{ matrix.build_mode }} ${{ matrix.cxx11 }} "" "" "" "OFF,1,x" "OFF,sm" "ALL" "arm64-gcc-toolchain.cmake"