Skip to content

Fix some crashes 2025-01-13 #837

Fix some crashes 2025-01-13

Fix some crashes 2025-01-13 #837

Workflow file for this run

name: 'MacOS-CI'
on:
push:
pull_request:
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
build:
name: Build
runs-on: ${{ matrix.os }}
continue-on-error: false
defaults:
run:
shell: bash
strategy:
fail-fast: false
matrix:
os:
# x86-64
- macos-13
# M1 processor
#- macos-14
python-version:
#- 3.12.8
- 3.13.1
compiler:
- AppleClang
#- clang
#- gcc
homebrew-gl:
- true
#- false
homebrew-al:
- true
#- false
ENABLE_PIE:
- 'ON'
#- 'OFF'
build-type:
- RelWithDebInfo
steps:
# specific setup for Python on Mac to ensure Python Version align
- name: Python Setup on Mac
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
id: vega-py-setup
with:
python-version: ${{ matrix.python-version }}
update-environment: true # false
- name: Install dependencies using homebrew
run: brew install boost-python3 gtk+3 gtkglext sdl libvorbis
# The following dependencies are already present within macos-* images:
# MacOS has a Developers Tools package from Apple that gets installed which
# provides some minimal functionality:
# XCode (which uses CLang/LLVM)
# git
- name: Install the latest version of Bash so we can rely on it
run: brew install bash
- name: Check out repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
fetch-depth: 2
submodules: false
# Ensure PRs are built against the PR Head as opposed to the merge commit
- name: Conditionally relocate to PR HEAD
if: github.event.pull_request
run: git checkout HEAD^2
- name: Bootstrap MacOS
run: script/bootstrap-mac.sh
# Note: it might be good to use a step to detect where OpenAL-Soft is
# installed and set it to a GHA variable that can be consumed below
- name: Build it
env:
MY_OS_NAME: macos
COMPILER: ${{ matrix.compiler }}
FLAGS: "-DCMAKE_BUILD_TYPE=${{ matrix.build-type }} -DCMAKE_FIND_FRAMEWORK=LAST -DENABLE_PIE=${{ matrix.ENABLE_PIE }} -DPython3_ROOT_DIR=${{ matrix.vega-py-setup.outputs.python-path }} -DPythonInstalledVia=Homebrew"
OPENALDIR: "/usr/local/opt/openal-soft"
Python3_ROOT_DIR: ${{ matrix.vega-py-setup.outputs.python-path }}
Python_ROOT_DIR: ${{ matrix.vega-py-setup.outputs.python-path }}
pythonLocation: ${{ matrix.vega-py-setup.outputs.python-path }}
PYTHONHOME: ""
PYTHONPATH: ""
run: script/cibuild $FLAGS
- name: Test
working-directory: ${{github.workspace}}/build
env:
GTEST_OUTPUT: xml
GTEST_COLOR: 1
run: ctest -V
- name: Upload test results
uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 #v4.3.3
if: failure()
with:
name: test_results_xml
path: ${{github.workspace}}/build/test-results/**/*.xml