diff --git a/.cirrus.yml b/.cirrus.yml index 57280fdfe2728..7deecdac49828 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -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 diff --git a/ci/cirrus.sh b/ci/cirrus.sh index fe54b5ea883c4..66119edf15fe3 100755 --- a/ci/cirrus.sh +++ b/ci/cirrus.sh @@ -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:-undefined}" 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