Skip to content

Commit

Permalink
ci: Use Homebrew's gcc in native macOS task
Browse files Browse the repository at this point in the history
Co-authored-by: Tim Ruffing <[email protected]>
  • Loading branch information
hebasto and real-or-random committed Aug 16, 2023
1 parent b2f6712 commit c144ddd
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
1 change: 1 addition & 0 deletions .cirrus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ task:
- env: {BUILD: distcheck}
brew_script:
- brew install automake libtool gcc
- ln -s /opt/homebrew/bin/gcc-?? /opt/homebrew/bin/gcc
test_script:
- ./ci/cirrus.sh
<< : *CAT_LOGS
Expand Down
7 changes: 7 additions & 0 deletions ci/cirrus.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,13 @@ esac

env >> test_env.log

# If gcc is requested, assert that it's in fact gcc (and not some symlinked Apple clang).
case "$CC" in
*gcc*)
$CC -v 2>&1 | grep -q "gcc version" || exit 1;
;;
esac

if [ -n "${CC+x}" ]; then
# The MSVC compiler "cl" doesn't understand "-v"
$CC -v || true
Expand Down

0 comments on commit c144ddd

Please sign in to comment.