CI, NFC: Update libomp installation approach on macOS in the GitHub action (#1094)
parent
5edb2eebf6
commit
0a3504c30a
|
@ -14,13 +14,13 @@ CMAKE_GENERATOR="Unix Makefiles"
|
|||
CMAKE_PREFIX_PATH=""
|
||||
if [ "$2" = "arm64" ]; then
|
||||
OSX_ARCHITECTURE="arm64"
|
||||
CMAKE_PREFIX_PATH="/tmp/libomp-arm64/libomp/11.0.1"
|
||||
CMAKE_PREFIX_PATH=$(find /tmp/libomp-arm64/libomp -depth 1)
|
||||
git apply cmake/libpng-macos-arm64.patch || echo "Could not apply patch, probably already patched..."
|
||||
mkdir build-arm64 || true
|
||||
cd build-arm64
|
||||
elif [ "$2" = "x86_64" ]; then
|
||||
OSX_ARCHITECTURE="x86_64"
|
||||
CMAKE_PREFIX_PATH="/tmp/libomp-x86_64/libomp/11.0.1"
|
||||
CMAKE_PREFIX_PATH=$(find /tmp/libomp-x86_64/libomp -depth 1)
|
||||
mkdir build || true
|
||||
cd build
|
||||
else
|
||||
|
|
|
@ -1,10 +1,12 @@
|
|||
#!/bin/sh -xe
|
||||
|
||||
if [ "$1" = "ci" ]; then
|
||||
curl -L https://bintray.com/homebrew/bottles/download_file?file_path=libomp-11.0.1.arm64_big_sur.bottle.tar.gz --output /tmp/libomp-arm64.tar.gz
|
||||
armloc=$(brew fetch --bottle-tag=arm64_big_sur libomp | grep -i downloaded | grep tar.gz | cut -f2 -d:)
|
||||
x64loc=$(brew fetch --bottle-tag=big_sur libomp | grep -i downloaded | grep tar.gz | cut -f2 -d:)
|
||||
cp $armloc /tmp/libomp-arm64.tar.gz
|
||||
mkdir /tmp/libomp-arm64 || true
|
||||
tar -xzvf /tmp/libomp-arm64.tar.gz -C /tmp/libomp-arm64
|
||||
curl -L https://bintray.com/homebrew/bottles/download_file?file_path=libomp-11.0.1.big_sur.bottle.tar.gz --output /tmp/libomp-x86_64.tar.gz
|
||||
cp $x64loc /tmp/libomp-x86_64.tar.gz
|
||||
mkdir /tmp/libomp-x86_64 || true
|
||||
tar -xzvf /tmp/libomp-x86_64.tar.gz -C /tmp/libomp-x86_64
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue