Add MacOS 13 runner #357
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: macOS | |
on: | |
push: | |
branches-ignore: | |
- '**/sources/**' | |
- '**/windows/**' | |
- '**/linux/**' | |
paths-ignore: | |
- '.github/workflows/sources.yml' | |
- '.github/workflows/linux.yml' | |
- '.github/workflows/windows.yml' | |
- 'data/artwork/**' | |
- 'data/packaging/linux/**' | |
- 'data/packaging/windows/**' | |
- 'data/platform/linux/**' | |
- 'data/platform/windows/**' | |
- 'docs/**' | |
- '.clang-format' | |
- '.git-blame-ignore-revs' | |
- '.git-properties' | |
- 'Changelog.txt' | |
- 'LICENSE' | |
- '**.md' | |
pull_request: | |
paths-ignore: | |
- '.github/workflows/sources.yml' | |
- '.github/workflows/linux.yml' | |
- '.github/workflows/windows.yml' | |
- 'data/artwork/**' | |
- 'data/packaging/linux/**' | |
- 'data/packaging/windows/**' | |
- 'data/platform/linux/**' | |
- 'data/platform/windows/**' | |
- 'docs/**' | |
- '.clang-format' | |
- '.git-blame-ignore-revs' | |
- '.git-properties' | |
- 'Changelog.txt' | |
- 'LICENSE' | |
- '**.md' | |
jobs: | |
bundle: | |
name: App Bundle | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [macos-13, macos-latest, macos-11] | |
steps: | |
- uses: actions/[email protected] | |
with: | |
fetch-tags: true | |
submodules: recursive | |
- name: Parse project data | |
run: | | |
echo "project_version=`sed -n -E -e "/^project\(wxFormBuilder[[:space:]]+VERSION[[:space:]]+(.*)[[:space:]]+LANGUAGES.*$/ s//-\1/p" CMakeLists.txt `" >> $GITHUB_ENV | |
- name: Setup environment | |
run: | | |
brew update | |
brew install cmake make wxwidgets boost | |
- name: Create build system | |
run: | | |
cmake -S . -B _build -G "Unix Makefiles" --install-prefix "$PWD/_install" -DCMAKE_BUILD_TYPE=Release | |
- name: Package build system | |
if: ${{ contains(github.ref, '/build/') }} | |
run: | | |
zip -ry wxFormBuilder-macOS-${{ matrix.os }}-build.zip _build | |
- name: Build | |
run: | | |
cmake --build _build --config Release -j `sysctl -n hw.ncpu` | |
- name: Test stage | |
run: | | |
_build/stage/wxFormBuilder.app/Contents/MacOS/wxFormBuilder -v | |
_build/stage/wxFormBuilder.app/Contents/MacOS/wxFormBuilder -g test/wxfbTest.fbp | |
- name: Install | |
run: | | |
cmake --install _build --config Release --strip | |
- name: Test install | |
run: | | |
_install/wxFormBuilder.app/Contents/MacOS/wxFormBuilder -v | |
_install/wxFormBuilder.app/Contents/MacOS/wxFormBuilder -g test/wxfbTest.fbp | |
- name: Package app bundle | |
run: | | |
cd _install | |
zip -ry ../wxFormBuilder${{ env.project_version }}-macos-`sw_vers -productVersion | cut -d . -f 1-2`-`uname -m`-bundle.zip wxFormBuilder.app | |
- uses: actions/[email protected] | |
if: ${{ contains(github.ref, '/build/') }} | |
with: | |
name: macOS Build Debugging ${{ matrix.os }} | |
path: | | |
wxFormBuilder-*-build.zip | |
- uses: actions/[email protected] | |
with: | |
name: App Bundle ${{ matrix.os }} | |
path: | | |
wxFormBuilder-*-bundle.zip |