Skip to content

Commit

Permalink
Update ci.yml to use MacOS 15 for arm osx jobs (#364)
Browse files Browse the repository at this point in the history
  • Loading branch information
mcbarton authored Dec 5, 2024
1 parent 41ea1c5 commit 60a2d9c
Showing 1 changed file with 72 additions and 35 deletions.
107 changes: 72 additions & 35 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -86,40 +86,40 @@ jobs:
cppyy: Off
llvm_enable_projects: "clang"
llvm_targets_to_build: "host;NVPTX"
- name: osx14-arm-clang-clang-repl-19
os: macos-14
- name: osx15-arm-clang-clang-repl-19
os: macos-15
compiler: clang
clang-runtime: '19'
cling: Off
cppyy: On
llvm_enable_projects: "clang;lld"
llvm_targets_to_build: "WebAssembly;host;NVPTX"
- name: osx14-arm-clang-clang-repl-18
os: macos-14
- name: osx15-arm-clang-clang-repl-18
os: macos-15
compiler: clang
clang-runtime: '18'
cling: Off
cppyy: On
llvm_enable_projects: "clang"
llvm_targets_to_build: "host;NVPTX"
- name: osx14-arm-clang-clang-repl-17
os: macos-14
- name: osx15-arm-clang-clang-repl-17
os: macos-15
compiler: clang
clang-runtime: '17'
cling: Off
cppyy: On
llvm_enable_projects: "clang"
llvm_targets_to_build: "host;NVPTX"
- name: osx14-arm-clang-clang-repl-16
os: macos-14
- name: osx15-arm-clang-clang-repl-16
os: macos-15
compiler: clang
clang-runtime: '16'
cling: Off
cppyy: On
llvm_enable_projects: "clang"
llvm_targets_to_build: "host;NVPTX"
- name: osx14-arm-clang-clang13-cling
os: macos-14
- name: osx15-arm-clang-clang13-cling
os: macos-15
compiler: clang
clang-runtime: '13'
cling: On
Expand Down Expand Up @@ -291,13 +291,31 @@ jobs:
echo "CC=gcc-${vers}" >> $GITHUB_ENV
echo "CXX=g++-${vers}" >> $GITHUB_ENV
else
echo "SDKROOT=$(xcrun --sdk macosx --show-sdk-path)" >> $GITHUB_ENV
#Use clang-15 and clang++-15 compiler that is installed on runner, instead of one
#provided by MacOS (could brew install clang-16/17 to use consistent version
#of clang)
echo "CC=$(brew --prefix llvm@15)/bin/clang" >> $GITHUB_ENV
echo "CXX=$(brew --prefix llvm@15)/bin/clang++" >> $GITHUB_ENV
export ARCHITECHURE=$(uname -m)
if [[ "$ARCHITECHURE" == "arm64" ]]; then
cling_on=$(echo "${{ matrix.cling }}" | tr '[:lower:]' '[:upper:]')
if [[ "${cling_on}" == "ON" ]]; then
brew install llvm@15
brew remove llvm@18
brew cleanup
#FIXME: Do not believe setting all these environment variables are necessary
# They were set to avoid using Xcodes libc++ and to stop CppInterOp using llvm@18 in tests
echo 'LDFLAGS="-L/opt/homebrew/opt/llvm@15/lib/ -L/opt/homebrew/opt/llvm@15/c++/"' >> $GITHUB_ENV
echo 'CPPFLAGS="-I/opt/homebrew/opt/llvm@15/include"' >> $GITHUB_ENV
echo 'CPATH="/opt/homebrew/include/"' >> $GITHUB_ENV
echo 'LIBRARY_PATH="/opt/homebrew/lib/"' >> $GITHUB_ENV
echo "CC=$(brew --prefix llvm@15)/bin/clang" >> $GITHUB_ENV
echo "CXX=$(brew --prefix llvm@15)/bin/clang++" >> $GITHUB_ENV
else
echo "CC=$(brew --prefix llvm@18)/bin/clang" >> $GITHUB_ENV
echo "CXX=$(brew --prefix llvm@18)/bin/clang++" >> $GITHUB_ENV
fi
else
echo "CC=$(brew --prefix llvm@15)/bin/clang" >> $GITHUB_ENV
echo "CXX=$(brew --prefix llvm@15)/bin/clang++" >> $GITHUB_ENV
fi
fi
echo "SDKROOT=$(xcrun --sdk macosx --show-sdk-path)" >> $GITHUB_ENV
env:
compiler: ${{ matrix.compiler }}

Expand Down Expand Up @@ -345,10 +363,11 @@ jobs:
if: ${{ runner.os == 'macOS' && steps.cache.outputs.cache-hit != 'true' }}
run: |
brew update
brew remove [email protected]
export ARCHITECHURE=$(uname -m)
if [[ "$ARCHITECHURE" != "x86_64" ]]; then
brew remove unxip
else
brew remove [email protected]
fi
# workaround for https://github.com/actions/setup-python/issues/577
for pkg in $(brew list | grep '^python@'); do
Expand Down Expand Up @@ -585,32 +604,32 @@ jobs:
# clang-runtime: '17'
# cling: Off
# cppyy: On
- name: osx14-arm-clang-clang-repl-19-cppyy
os: macos-14
- name: osx15-arm-clang-clang-repl-19-cppyy
os: macos-15
compiler: clang
clang-runtime: '19'
cling: Off
cppyy: On
- name: osx14-arm-clang-clang-repl-18-cppyy
os: macos-14
- name: osx15-arm-clang-clang-repl-18-cppyy
os: macos-15
compiler: clang
clang-runtime: '18'
cling: Off
cppyy: On
- name: osx14-arm-clang-clang-repl-17-cppyy
os: macos-14
- name: osx15-arm-clang-clang-repl-17-cppyy
os: macos-15
compiler: clang
clang-runtime: '17'
cling: Off
cppyy: On
- name: osx14-arm-clang-clang-repl-16
os: macos-14
- name: osx15-arm-clang-clang-repl-16
os: macos-15
compiler: clang
clang-runtime: '16'
cling: Off
cppyy: Off
- name: osx14-arm-clang-clang13-cling-cppyy
os: macos-14
- name: osx15-arm-clang-clang13-cling-cppyy
os: macos-15
compiler: clang
clang-runtime: '13'
cling: On
Expand Down Expand Up @@ -761,11 +780,29 @@ jobs:
echo "CXX=g++-${vers}" >> $GITHUB_ENV
else
echo "SDKROOT=$(xcrun --sdk macosx --show-sdk-path)" >> $GITHUB_ENV
#Use clang-15 and clang++-15 compiler that is installed on runner, instead of one
#provided by MacOS (could brew install clang-16/17 to use consistent version
#of clang)
echo "CC=$(brew --prefix llvm@15)/bin/clang" >> $GITHUB_ENV
echo "CXX=$(brew --prefix llvm@15)/bin/clang++" >> $GITHUB_ENV
export ARCHITECHURE=$(uname -m)
if [[ "$ARCHITECHURE" == "arm64" ]]; then
cling_on=$(echo "${{ matrix.cling }}" | tr '[:lower:]' '[:upper:]')
if [[ "${cling_on}" == "ON" ]]; then
brew install llvm@15
brew remove llvm@18
brew cleanup
#FIXME: Do not believe setting all these environment variables are necessary
# They were set to avoid using Xcodes libc++ and to stop CppInterOp using llvm@18 in tests
echo 'LDFLAGS="-L/opt/homebrew/opt/llvm@15/lib/ -L/opt/homebrew/opt/llvm@15/c++/"' >> $GITHUB_ENV
echo 'CPPFLAGS="-I/opt/homebrew/opt/llvm@15/include"' >> $GITHUB_ENV
echo 'CPATH="/opt/homebrew/include/"' >> $GITHUB_ENV
echo 'LIBRARY_PATH="/opt/homebrew/lib/"' >> $GITHUB_ENV
echo "CC=$(brew --prefix llvm@15)/bin/clang" >> $GITHUB_ENV
echo "CXX=$(brew --prefix llvm@15)/bin/clang++" >> $GITHUB_ENV
else
echo "CC=$(brew --prefix llvm@18)/bin/clang" >> $GITHUB_ENV
echo "CXX=$(brew --prefix llvm@18)/bin/clang++" >> $GITHUB_ENV
fi
else
echo "CC=$(brew --prefix llvm@15)/bin/clang" >> $GITHUB_ENV
echo "CXX=$(brew --prefix llvm@15)/bin/clang++" >> $GITHUB_ENV
fi
fi
env:
compiler: ${{ matrix.compiler }}
Expand Down Expand Up @@ -813,9 +850,9 @@ jobs:
if: runner.os == 'macOS'
run: |
brew update --force
brew remove [email protected]
export ARCHITECHURE=$(uname -m)
if [[ "$ARCHITECHURE" == "x86_64" ]]; then
brew remove [email protected]
brew remove swiftlint
else
brew remove unxip
Expand Down Expand Up @@ -1149,8 +1186,8 @@ jobs:
cling: Off
micromamba_shell_init: bash
emsdk_ver: "3.1.45"
- name: osx14-arm-clang-clang-repl-19-emscripten_wasm
os: macos-14
- name: osx15-arm-clang-clang-repl-19-emscripten_wasm
os: macos-15
compiler: clang
clang-runtime: '19'
cling: Off
Expand Down

0 comments on commit 60a2d9c

Please sign in to comment.