Skip to content

Commit

Permalink
Choose the best available macOS arch
Browse files Browse the repository at this point in the history
  • Loading branch information
pcolby committed Oct 4, 2024
1 parent 271da5c commit f7f58ef
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -214,8 +214,13 @@ jobs:
if-no-files-found: error
- name: Choose target architectures
run: |
# \todo more logic here
echo "CMAKE_OSX_ARCHITECTURES=arm64;x86_64" >> $GITHUB_ENV
# Qt Online Installer only provides x86-64 binaries (not arm64) prior to Qt 6.2.0.
if [[ '${{ matrix.qt }}' =~ ^(5|6\.[01])\. ]]; then arch=x86_64
# GitHub's macos-15 runners only support arm64, and no longer support x86-64.
elif [[ '${{ matrix.os }} == 'macos-15' ]]; then arch=arm64
# Otherwise, default to universal binaries, where possible.
else arch='arm64;x86_64'; fi
echo "CMAKE_OSX_ARCHITECTURES=${arch}" >> $GITHUB_ENV
- name: Build
id: build
env:
Expand All @@ -230,6 +235,7 @@ jobs:
-S "$GITHUB_WORKSPACE" -B "$RUNNER_TEMP"
echo "dokitVersion=$(cat "$RUNNER_TEMP/version.txt")" | tee -a "$GITHUB_OUTPUT"
{ echo -n 'tap='; [[ '${{ matrix.qt }}' =~ ^5\.1[2-9]|6 ]] && echo true || echo false; } | tee -a "$GITHUB_OUTPUT"
exit 1 # \todo Bow out early for now.
cmake --build "$RUNNER_TEMP" -- VERBOSE=1
find "$RUNNER_TEMP" -name 'Info.plist'
find "$RUNNER_TEMP" -name 'Info.plist' -execdir cat '{}' \;
Expand Down

0 comments on commit f7f58ef

Please sign in to comment.