Provisioning: build cmake from source on macOS 10.13

Change-Id: Ifada0cf62d1e75e8cab3e3bbe6250718747d0703
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
This commit is contained in:
Liang Qi
2019-03-18 13:16:13 +01:00
parent 05eaaeda4b
commit 8b0a10d1c1
2 changed files with 8 additions and 6 deletions

View File

@@ -57,14 +57,16 @@ sudo rm "$targetFile"
echo "Configuring and building cmake"
cd "$targetDir"
if uname -a |grep -qv Darwin; then
if uname -a |grep -q Darwin; then
./bootstrap --prefix="$(xcrun --sdk macosx --show-sdk-path)/usr/local"
SetEnvVar PATH "\$PATH:$(xcrun --sdk macosx --show-sdk-path)/usr/local/bin"
else
./bootstrap --prefix="$cmakeHome"
make
make install
SetEnvVar "PATH" "$cmakeHome/bin:\$PATH"
fi
make
sudo make install
sudo rm -r "$targetDir"
SetEnvVar "PATH" "$cmakeHome/bin:\$PATH"
echo "CMake = $version" >> ~/versions.txt

View File

@@ -3,4 +3,4 @@
set -ex
BASEDIR=$(dirname "$0")
"$BASEDIR/../common/macos/cmake.sh"
"$BASEDIR/../common/unix/install_cmake.sh"