Skip to content

0.9.x Build Troubleshooting Early December 2023 SGT #448

0.9.x Build Troubleshooting Early December 2023 SGT

0.9.x Build Troubleshooting Early December 2023 SGT #448

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 }}
defaults:
run:
shell: bash
strategy:
fail-fast: false
matrix:
os:
- macos-12
python-version:
- 3.12
homebrew-gl:
- true
homebrew-al:
- true
- false
env:
HOMEBREW_NO_AUTO_UPDATE: 1
HOMEBREW_NO_INSTALL_UPGRADE: 1
HOMEBREW_NO_INSTALLED_DEPENDENTS_CHECK: 1
PYTHON_VERSION_STRING: "python@${{ matrix.python-version }}"
steps:
- name: Check out repository
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 #v4.1.1
with:
fetch-depth: 2
submodules: false
# The following dependencies are already present within macos-* images:
# - clang (llvm)
# - cmake
# - expat
# - gcc
# - git
# - jpeg
# - libpng
# - libvorbis
# - python
#
# Note, though, that the Python version "varies between runners and can be changed unexpectedly",
# according to https://github.com/actions/setup-python#basic-usage .
# Hence the need to specify a particular Python version.
#- name: Set up Python
# uses: actions/setup-python@65d7f2d534ac1bc67fcd62888c5f4f3d2cb2b236 #v4.7.1
# with:
# python-version: ${{ matrix.python-version }}
# check-latest: true
- name: Install dependencies using homebrew
run: |
brew update
. ./script/brew-install-for-cmake.sh openssl@3 0
. ./script/brew-install-for-cmake.sh $PYTHON_VERSION_STRING 0
. ./script/brew-install-for-cmake.sh boost 0
. ./script/brew-install-for-cmake.sh boost-python3 0
. ./script/brew-install-for-cmake.sh gtk+3 1
. ./script/brew-install-for-cmake.sh gtkglext 1
. ./script/brew-install-for-cmake.sh sdl2 1
# The following Apple-provided libraries are deprecated:
# * OpenGL as of macOS 10.14
# * GLUT as of macOS 10.9
- name: Optionally install homebrewed OpenGL and GLUT
if: ${{ matrix.homebrew-gl }}
run: |
. ./script/brew-install-for-cmake.sh mesa 1
. ./script/brew-install-for-cmake.sh mesa-glu 1
. ./script/brew-install-for-cmake.sh freeglut 1
ln -s /usr/local/include/GL /usr/local/include/OpenGL
ln -s /usr/local/include/GL /usr/local/include/GLUT
# The Apple-provided OpenAL is deprecated as of macOS 10.15
- name: Optionally install homebrewed OpenAL
if: ${{ matrix.homebrew-al }}
run: |
. ./script/brew-install-for-cmake.sh openal-soft 1
export OPENALDIR=$(brew --prefix openal-soft)
- name: Build it
env:
MY_OS_NAME: macos
FLAGS: '-DCMAKE_FIND_FRAMEWORK=LAST -DCMAKE_FIND_APPBUNDLE=LAST'
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@a8a3f3ad30e3422c9c7b888a15615d19a852ae32 #v3.1.3
if: failure()
with:
name: test_results_xml
path: ${{github.workspace}}/build/test-results/**/*.xml