benchmark: Correct misspelled file name #1192
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
# Copyright (c) Omar Boukli-Hacene. All rights reserved. | |
# Distributed under an MIT-style license that can be | |
# found in the LICENSE file. | |
# SPDX-License-Identifier: MIT | |
name: Xcode build on macOS | |
on: | |
pull_request: | |
branches: | |
- main | |
push: | |
branches: | |
- main | |
workflow_dispatch: | |
permissions: {} | |
jobs: | |
build: | |
name: Build | |
runs-on: macos-latest | |
env: | |
BUILD_PATH: ${{ github.workspace }}/xcode/build | |
VCPKG_BINARY_SOURCES: clear;x-gha,readwrite | |
steps: | |
- name: Check out repository | |
uses: actions/checkout@v4 | |
with: | |
persist-credentials: false | |
- name: Check out vcpkg | |
uses: actions/checkout@v4 | |
with: | |
repository: microsoft/vcpkg | |
path: ${{ github.workspace }}/vcpkg | |
persist-credentials: false | |
- name: Export GitHub Actions cache environment variables | |
uses: actions/github-script@v7 | |
with: | |
script: |- | |
core.exportVariable( | |
'ACTIONS_CACHE_URL', process.env.ACTIONS_CACHE_URL || '' | |
); | |
core.exportVariable( | |
'ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN || '' | |
); | |
- name: Set default Xcode release | |
env: | |
XCODE_RELEASE: "16.0" | |
run: >- | |
sudo xcode-select | |
-switch '/Applications/Xcode_${{ env.XCODE_RELEASE }}.app' | |
- name: Bootstrap vcpkg | |
run: ./vcpkg/bootstrap-vcpkg.sh -disableMetrics | |
- name: Install boost-test | |
run: ./vcpkg/vcpkg install boost-test | |
- name: Install SDL2 | |
run: |- | |
./vcpkg/vcpkg install --triplet x64-osx-dynamic sdl2 | |
./vcpkg/vcpkg install --triplet arm64-osx-dynamic sdl2 | |
- name: Make build script executable | |
run: chmod +x xcode/Tromino2d/scripts/uni.sh | |
- name: Build trominocli | |
run: >- | |
xcodebuild | |
-workspace TrominoPuzzle.xcworkspace | |
-scheme TrominoCli | |
-configuration Release | |
CONFIGURATION_BUILD_DIR=${{ env.BUILD_PATH }} | |
build | |
working-directory: xcode | |
- name: Build tromino2d | |
run: >- | |
xcodebuild | |
-workspace TrominoPuzzle.xcworkspace | |
-scheme Tromino2d | |
-configuration Release | |
CONFIGURATION_BUILD_DIR=${{ env.BUILD_PATH }} | |
build | |
working-directory: xcode | |
- name: Build unit tests | |
run: > | |
xcodebuild | |
-workspace TrominoPuzzle.xcworkspace | |
-scheme UnitTests | |
-configuration Debug | |
CONFIGURATION_BUILD_DIR=${{ env.BUILD_PATH }} | |
build | |
working-directory: xcode | |
- name: Run unit tests | |
run: ./UnitTests | |
working-directory: ${{ env.BUILD_PATH }} | |
- name: Compute SHA512 of artifacts | |
run: | | |
ls -Al | grep -v '^d' | |
shasum --algorithm 512 --binary UnitTests | |
shasum --algorithm 512 --binary libSDL2-2.0.0.dylib | |
shasum --algorithm 512 --binary libtromino-validation.a | |
shasum --algorithm 512 --binary libtromino.a | |
shasum --algorithm 512 --binary libtromino2d.a | |
shasum --algorithm 512 --binary tromino | |
shasum --algorithm 512 --binary tromino2d | |
working-directory: ${{ env.BUILD_PATH }} |