diff options
Diffstat (limited to 'coin/provisioning/common/macos')
-rwxr-xr-x | coin/provisioning/common/macos/InstallAppFromCompressedFileFromURL.sh | 136 | ||||
-rwxr-xr-x | coin/provisioning/common/macos/InstallPKGFromURL.sh | 104 | ||||
-rwxr-xr-x | coin/provisioning/common/macos/cmake.sh | 51 | ||||
-rwxr-xr-x | coin/provisioning/common/macos/fbx_macos.sh | 79 | ||||
-rwxr-xr-x | coin/provisioning/common/macos/homebrew.sh | 3 | ||||
-rwxr-xr-x | coin/provisioning/common/macos/install-commandlinetools.sh | 88 | ||||
-rwxr-xr-x | coin/provisioning/common/macos/install_xcode.sh | 91 | ||||
-rwxr-xr-x | coin/provisioning/common/macos/pip.sh | 5 | ||||
-rwxr-xr-x | coin/provisioning/common/macos/python3.sh | 52 | ||||
-rwxr-xr-x | coin/provisioning/common/macos/system_updates.sh | 40 | ||||
-rwxr-xr-x | coin/provisioning/common/macos/virtualenv.sh | 3 |
11 files changed, 652 insertions, 0 deletions
diff --git a/coin/provisioning/common/macos/InstallAppFromCompressedFileFromURL.sh b/coin/provisioning/common/macos/InstallAppFromCompressedFileFromURL.sh new file mode 100755 index 00000000..4d2ba1f8 --- /dev/null +++ b/coin/provisioning/common/macos/InstallAppFromCompressedFileFromURL.sh @@ -0,0 +1,136 @@ +#!/usr/bin/env bash + +############################################################################# +## +## Copyright (C) 2017 The Qt Company Ltd. +## Contact: http://www.qt.io/licensing/ +## +## This file is part of the provisioning scripts of the Qt Toolkit. +## +## $QT_BEGIN_LICENSE:LGPL21$ +## Commercial License Usage +## Licensees holding valid commercial Qt licenses may use this file in +## accordance with the commercial license agreement provided with the +## Software or, alternatively, in accordance with the terms contained in +## a written agreement between you and The Qt Company. For licensing terms +## and conditions see http://www.qt.io/terms-conditions. For further +## information use the contact form at http://www.qt.io/contact-us. +## +## GNU Lesser General Public License Usage +## Alternatively, this file may be used under the terms of the GNU Lesser +## General Public License version 2.1 or version 3 as published by the Free +## Software Foundation and appearing in the file LICENSE.LGPLv21 and +## LICENSE.LGPLv3 included in the packaging of this file. Please review the +## following information to ensure the GNU Lesser General Public License +## requirements will be met: https://www.gnu.org/licenses/lgpl.html and +## http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +## +## As a special exception, The Qt Company gives you certain additional +## rights. These rights are described in The Qt Company LGPL Exception +## version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +## +## $QT_END_LICENSE$ +## +############################################################################# + +# This script receives URLs to a compressed file. It then downloads it, +# uncompresses it and installs it by default +# to /Applications/. This can be overridden by a target parameter. + +# shellcheck source=try_catch.sh +source "${BASH_SOURCE%/*}/../unix/try_catch.sh" +# shellcheck source=DownloadURL.sh +source "${BASH_SOURCE%/*}/../unix/DownloadURL.sh" + +ExceptionDownload=99 +ExceptionCreateTmpFile=100 +ExceptionCreateTmpDirectory=101 +ExceptionUncompress=102 +ExceptionMoveApp=103 +ExceptionDeleteTmpFile=104 +ExceptionRemoveTmpDirectory=105 +ExceptionUnknownFormat=106 + + +function InstallAppFromCompressedFileFromURL { + url=$1 + url_alt=$2 + expectedSha1=$3 + appPrefix=$4 + target=$5 + + if [ "" == "$target" ]; then + target="/Applications/" + fi + + try + ( + basefilename=${url##*/} + extension=${basefilename##*.} + filename=${basefilename%.*} + if [ "$extension" == "gz" ] && [ "${filename##*.}" == "tar" ]; then + extension="tar.gz" + fi + + echo "Extension for file: $extension" + echo "Creating temporary file and directory" + targetFile=$(mktemp "$TMPDIR$(uuidgen).$extension") || throw $ExceptionCreateTmpFile + # macOS 10.10 mktemp does require prefix + if [[ $OSTYPE == "darwin14" ]]; then + targetDirectory=$(mktemp -d -t '10.10') || throw $ExceptionCreateTmpDirectory + else + targetDirectory=$(mktemp -d) || throw $ExceptionCreateTmpDirectory + fi + (DownloadURL "$url" "$url_alt" "$expectedSha1" "$targetFile") || throw $ExceptionDownload + echo "Uncompress $targetFile" + case $extension in + "tar.gz") + tar -xzf "$targetFile" --directory "$targetDirectory" || throw $ExceptionUncompress + ;; + "zip") + unzip "$targetFile" -d "$targetDirectory" || throw $ExceptionUncompress + ;; + *) + throw $ExceptionUnknownFormat + ;; + esac + echo "Moving app to '$target'" + sudo mv "$targetDirectory/$appPrefix/"* "$target" || throw $ExceptionMoveApp + echo "Removing file '$targetFile'" + rm "$targetFile" || throw $ExceptionDeleteTmpFile + echo "Removing directory '$targetDirectory'" + rm -rf "$targetDirectory" || throw $ExceptionRemoveTmpDirectory + ) + + catch || { + case $ex_code in + $ExceptionDownload) + exit 1; + ;; + $ExceptionCreateTmpFile) + echo "Failed to create temporary file" + exit 1; + ;; + $ExceptionUncompress) + echo "Failed extracting compressed file." + exit 1; + ;; + $ExceptionMoveApp) + echo "Failed moving app to '$target'." + exit 1; + ;; + $ExceptionDeleteTmpFile) + echo "Failed deleting temporary file." + exit 1; + ;; + $ExceptionRemoveTmpDirectory) + echo "Failed deleting temporary file." + exit 1; + ;; + $ExceptionUnknownFormat) + echo "Unknown file format." + exit 1; + ;; + esac + } +} diff --git a/coin/provisioning/common/macos/InstallPKGFromURL.sh b/coin/provisioning/common/macos/InstallPKGFromURL.sh new file mode 100755 index 00000000..881086ba --- /dev/null +++ b/coin/provisioning/common/macos/InstallPKGFromURL.sh @@ -0,0 +1,104 @@ +#!/usr/bin/env bash + +############################################################################# +## +## Copyright (C) 2017 The Qt Company Ltd. +## Contact: http://www.qt.io/licensing/ +## +## This file is part of the provisioning scripts of the Qt Toolkit. +## +## $QT_BEGIN_LICENSE:LGPL21$ +## Commercial License Usage +## Licensees holding valid commercial Qt licenses may use this file in +## accordance with the commercial license agreement provided with the +## Software or, alternatively, in accordance with the terms contained in +## a written agreement between you and The Qt Company. For licensing terms +## and conditions see http://www.qt.io/terms-conditions. For further +## information use the contact form at http://www.qt.io/contact-us. +## +## GNU Lesser General Public License Usage +## Alternatively, this file may be used under the terms of the GNU Lesser +## General Public License version 2.1 or version 3 as published by the Free +## Software Foundation and appearing in the file LICENSE.LGPLv21 and +## LICENSE.LGPLv3 included in the packaging of this file. Please review the +## following information to ensure the GNU Lesser General Public License +## requirements will be met: https://www.gnu.org/licenses/lgpl.html and +## http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +## +## As a special exception, The Qt Company gives you certain additional +## rights. These rights are described in The Qt Company LGPL Exception +## version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +## +## $QT_END_LICENSE$ +## +############################################################################# + +# shellcheck source=try_catch.sh +source "${BASH_SOURCE%/*}/../unix/try_catch.sh" + +ExceptionCreateTmpFile=100 +ExceptionDownloadPrimaryUrl=101 +ExceptionDownloadAltUrl=102 +ExceptionSHA1=103 +ExceptionInstallerPKG=104 +ExceptionDeleteTmpFile=105 + + +function InstallPKGFromURL { + url=$1 + url_alt=$2 + expectedSha1=$3 + targetDirectory=$4 + + try + ( + echo "Creating temporary file" + targetFile=$(mktemp "$TMPDIR$(uuidgen).pkg") || trow $ExceptionCreateTmpFile + try + ( + echo "Downloading PKG from primary URL '$url'" + curl --fail -L --retry 5 --retry-delay 5 -o "$targetFile" "$url" || throw $ExceptionDownloadPrimaryUrl + ) + catch || { + case $ex_code in + $ExceptionDownloadPrimaryUrl) + echo "Failed to download '$url' multiple times" + echo "Downloading PKG from alternative URL '$url_alt'" + curl --fail -L --retry 5 --retry-delay 5 -o "$targetFile" "$url_alt" || throw $ExceptionDownloadAltUrl + ;; + esac + } + echo "Checking SHA1 on PKG '$targetFile'" + echo "$expectedSha1 *$targetFile" > $targetFile.sha1 + /usr/bin/shasum --check $targetFile.sha1 || throw $ExceptionSHA1 + echo "Run installer on PKG" + sudo installer -package "$targetFile" -target "$targetDirectory" || throw $ExceptionInstallerPKG + echo "Removing file '$targetFile'" + rm "$targetFile" || throw $ExceptionDeleteTmpFile + ) + + catch || { + case $ex_code in + $ExceptionCreateTmpFile) + echo "Failed to create temporary file" + exit 1; + ;; + $ExceptionDownloadAltUrl) + echo "Failed downloading PKG from primary and alternative URLs" + exit 1; + ;; + $ExceptionSHA1) + echo "Failed to check sha1sum." + exit 1; + ;; + $ExceptionInstallerPKG) + echo "Failed running installer on PKG." + exit 1; + ;; + $ExceptionDeleteTmpFile) + echo "Failed deleting temporary file." + exit 1; + ;; + esac + } +} diff --git a/coin/provisioning/common/macos/cmake.sh b/coin/provisioning/common/macos/cmake.sh new file mode 100755 index 00000000..c727c8ff --- /dev/null +++ b/coin/provisioning/common/macos/cmake.sh @@ -0,0 +1,51 @@ +#!/usr/bin/env bash + +############################################################################# +## +## Copyright (C) 2017 The Qt Company Ltd. +## Contact: http://www.qt.io/licensing/ +## +## This file is part of the provisioning scripts of the Qt Toolkit. +## +## $QT_BEGIN_LICENSE:LGPL21$ +## Commercial License Usage +## Licensees holding valid commercial Qt licenses may use this file in +## accordance with the commercial license agreement provided with the +## Software or, alternatively, in accordance with the terms contained in +## a written agreement between you and The Qt Company. For licensing terms +## and conditions see http://www.qt.io/terms-conditions. For further +## information use the contact form at http://www.qt.io/contact-us. +## +## GNU Lesser General Public License Usage +## Alternatively, this file may be used under the terms of the GNU Lesser +## General Public License version 2.1 or version 3 as published by the Free +## Software Foundation and appearing in the file LICENSE.LGPLv21 and +## LICENSE.LGPLv3 included in the packaging of this file. Please review the +## following information to ensure the GNU Lesser General Public License +## requirements will be met: https://www.gnu.org/licenses/lgpl.html and +## http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +## +## As a special exception, The Qt Company gives you certain additional +## rights. These rights are described in The Qt Company LGPL Exception +## version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +## +## $QT_END_LICENSE$ +## +############################################################################# + +# This script installs CMake + +# CMake is needed for autotests that verify that Qt can be built with CMake + +# shellcheck source=./InstallAppFromCompressedFileFromURL.sh +source "${BASH_SOURCE%/*}/InstallAppFromCompressedFileFromURL.sh" + +PrimaryUrl="http://ci-files01-hki.intra.qt.io/input/mac/osx_10.11_el_capitan/cmake-3.6.2-Darwin-x86_64.tar.gz" +AltUrl="https://cmake.org/files/v3.6/cmake-3.6.2-Darwin-x86_64.tar.gz" +SHA1="13835afa3aea939e07a7ecccedcc041dd8c3a86e" +appPrefix="cmake-3.6.2-Darwin-x86_64" + +InstallAppFromCompressedFileFromURL "$PrimaryUrl" "$AltUrl" "$SHA1" "$appPrefix" + +echo "export PATH=/Applications/CMake.app/Contents/bin:\$PATH" >> ~/.bashrc +echo "CMake = 3.6.2" >> ~/versions.txt diff --git a/coin/provisioning/common/macos/fbx_macos.sh b/coin/provisioning/common/macos/fbx_macos.sh new file mode 100755 index 00000000..9dc97814 --- /dev/null +++ b/coin/provisioning/common/macos/fbx_macos.sh @@ -0,0 +1,79 @@ +#!/usr/bin/env bash +############################################################################# +## +## Copyright (C) 2017 The Qt Company Ltd. +## Contact: http://www.qt.io/licensing/ +## +## This file is part of the provisioning scripts of the Qt Toolkit. +## +## $QT_BEGIN_LICENSE:LGPL21$ +## Commercial License Usage +## Licensees holding valid commercial Qt licenses may use this file in +## accordance with the commercial license agreement provided with the +## Software or, alternatively, in accordance with the terms contained in +## a written agreement between you and The Qt Company. For licensing terms +## and conditions see http://www.qt.io/terms-conditions. For further +## information use the contact form at http://www.qt.io/contact-us. +## +## GNU Lesser General Public License Usage +## Alternatively, this file may be used under the terms of the GNU Lesser +## General Public License version 2.1 or version 3 as published by the Free +## Software Foundation and appearing in the file LICENSE.LGPLv21 and +## LICENSE.LGPLv3 included in the packaging of this file. Please review the +## following information to ensure the GNU Lesser General Public License +## requirements will be met: https://www.gnu.org/licenses/lgpl.html and +## http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +## +## As a special exception, The Qt Company gives you certain additional +## rights. These rights are described in The Qt Company LGPL Exception +## version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +## +## $QT_END_LICENSE$ +## +############################################################################# + +# This script installs FBX SDK + +# shellcheck source=./../unix/try_catch.sh +source "${BASH_SOURCE%/*}/../unix/try_catch.sh" + +fileName="fbx20161_2_fbxsdk_clang_mac.pkg.tgz" +targetFolder="/opt/fbx" +cachedUrl="/net/ci-files01-hki.intra.qt.io/hdd/www/input/fbx/$fileName" +officialUrl="http://download.autodesk.com/us/fbx_release_older/2016.1.2/$fileName" +sha1="f82535423c700c605320c52e13e781c92208ec6b" +targetFolder="/tmp" +targetFile="$targetFolder/$fileName" +installer="$targetFolder/fbx20161_2_fbxsdk_clang_macos.pkg" + +ExceptionExtractPrimaryUrl=100 + +try +( + echo "Extracting '$cachedUrl'" + tar -xzf "$cachedUrl" -C "$targetFolder" || throw $ExceptionExtractPrimaryUrl +) +catch || { + case $ex_code in + $ExceptionExtractPrimaryUrl) + set -e + echo "Failed to uncompress from '$cachedUrl'" + echo "Downloading from '$officialUrl'" + curl --fail -L --retry 5 --retry-delay 5 -o "$targetFile" "$officialUrl" || exit 1; + echo "Checking SHA1 on PKG '$targetFile'" + echo "$sha1 *$targetFile" > $targetFile.sha1 + shasum --check $targetFile.sha1 + echo "Extracting '$targetFile'" + tar -xzf "$targetFile" -C "$targetFolder" || exit 1; + ;; + esac +} +set -e +rm -rf "$targetFile" +echo "Running installer for '$installer'" +sudo installer -pkg "$installer" -target "/" + +# Set env variables +echo "export FBXSDK=/Applications/Autodesk/FBX\ SDK/2016.1.2/" >> ~/.bashrc +echo "FBX SDK = 2016.1.2" >> ~/versions.txt + diff --git a/coin/provisioning/common/macos/homebrew.sh b/coin/provisioning/common/macos/homebrew.sh new file mode 100755 index 00000000..a6efe123 --- /dev/null +++ b/coin/provisioning/common/macos/homebrew.sh @@ -0,0 +1,3 @@ +#!/usr/bin/env bash +# Will install homebrew package manager for macOS +/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" </dev/null diff --git a/coin/provisioning/common/macos/install-commandlinetools.sh b/coin/provisioning/common/macos/install-commandlinetools.sh new file mode 100755 index 00000000..d57e1d2f --- /dev/null +++ b/coin/provisioning/common/macos/install-commandlinetools.sh @@ -0,0 +1,88 @@ +#!/usr/bin/env bash + +############################################################################# +## +## Copyright (C) 2017 The Qt Company Ltd. +## Contact: http://www.qt.io/licensing/ +## +## This file is part of the test suite of the Qt Toolkit. +## +## $QT_BEGIN_LICENSE:LGPL21$ +## Commercial License Usage +## Licensees holding valid commercial Qt licenses may use this file in +## accordance with the commercial license agreement provided with the +## Software or, alternatively, in accordance with the terms contained in +## a written agreement between you and The Qt Company. For licensing terms +## and conditions see http://www.qt.io/terms-conditions. For further +## information use the contact form at http://www.qt.io/contact-us. +## +## GNU Lesser General Public License Usage +## Alternatively, this file may be used under the terms of the GNU Lesser +## General Public License version 2.1 or version 3 as published by the Free +## Software Foundation and appearing in the file LICENSE.LGPLv21 and +## LICENSE.LGPLv3 included in the packaging of this file. Please review the +## following information to ensure the GNU Lesser General Public License +## requirements will be met: https://www.gnu.org/licenses/lgpl.html and +## http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +## +## As a special exception, The Qt Company gives you certain additional +## rights. These rights are described in The Qt Company LGPL Exception +## version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +## +## $QT_END_LICENSE$ +## +############################################################################# +source "${BASH_SOURCE%/*}/../unix/DownloadURL.sh" +source "${BASH_SOURCE%/*}/../unix/try_catch.sh" +set -ex + +# Command line tools is need by homebrew + +function InstallCommandLineTools { + + ExceptionMount=101 + ExceptionInstall=102 + ExceptionUnmount=103 + + url=$1 + url_alt=$2 + expectedSha1=$3 + packageName=$4 + version=$5 + + try + ( + DownloadURL $url $url_alt $expectedSha1 /tmp/$packageName + echo "Mounting $packageName" + hdiutil attach /tmp/$packageName || throw $ExceptionMount + cd "/Volumes/Command Line Developer Tools" + echo "Installing" + sudo installer -verbose -pkg *.pkg -target / || throw $ExceptionInstall + cd / + # Let's fait for 5 second before unmounting. Sometimes resource is busy and cant be unmounted + sleep 3 + echo "Unmounting" + umount /Volumes/Command\ Line\ Developer\ Tools/ || throw $ExceptionUnmount + echo "Removing $packageName" + rm /tmp/$packageName + + echo "Command Line Tools = $version" >> ~/versions.txt + ) + catch || { + case $ex_code in + $ExceptionMount) + echo "Failed to mount" + exit 1; + ;; + $ExceptionInstall) + echo "Failed to install" + exit 1; + ;; + $ExceptionUnmount) + echo "Failed to unmount" + exit 1; + + esac + } + +} diff --git a/coin/provisioning/common/macos/install_xcode.sh b/coin/provisioning/common/macos/install_xcode.sh new file mode 100755 index 00000000..1fe611b3 --- /dev/null +++ b/coin/provisioning/common/macos/install_xcode.sh @@ -0,0 +1,91 @@ +#!/usr/bin/env bash + +############################################################################# +## +## Copyright (C) 2017 The Qt Company Ltd. +## Contact: http://www.qt.io/licensing/ +## +## This file is part of the provisioning scripts of the Qt Toolkit. +## +## $QT_BEGIN_LICENSE:LGPL21$ +## Commercial License Usage +## Licensees holding valid commercial Qt licenses may use this file in +## accordance with the commercial license agreement provided with the +## Software or, alternatively, in accordance with the terms contained in +## a written agreement between you and The Qt Company. For licensing terms +## and conditions see http://www.qt.io/terms-conditions. For further +## information use the contact form at http://www.qt.io/contact-us. +## +## GNU Lesser General Public License Usage +## Alternatively, this file may be used under the terms of the GNU Lesser +## General Public License version 2.1 or version 3 as published by the Free +## Software Foundation and appearing in the file LICENSE.LGPLv21 and +## LICENSE.LGPLv3 included in the packaging of this file. Please review the +## following information to ensure the GNU Lesser General Public License +## requirements will be met: https://www.gnu.org/licenses/lgpl.html and +## http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +## +## As a special exception, The Qt Company gives you certain additional +## rights. These rights are described in The Qt Company LGPL Exception +## version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +## +## $QT_END_LICENSE$ +## +############################################################################# + +# This script installs Xcode +# Prerequisites: Have Xcode prefetched to local cache as xz compressed. +# This can be achieved by fetching Xcode_8.xip from Apple Store. +# Uncompress it with 'xar -xf Xcode_8.xip' +# Then get https://gist.githubusercontent.com/pudquick/ff412bcb29c9c1fa4b8d/raw/24b25538ea8df8d0634a2a6189aa581ccc6a5b4b/parse_pbzx2.py +# with which you can run 'python parse_pbzx2.py Content'. +# This will give you a file called "Content.part00.cpio.xz" that +# can be renamed to Xcode_8.xz for this script. + + + +# shellcheck source=../common/unix/try_catch.sh +source "${BASH_SOURCE%/*}/../unix/try_catch.sh" + +function InstallXCode() +{ + ExceptionCPIO=103 + ExceptionAcceptLicense=105 + ExceptionDeveloperMode=113 + + sourceFile=$1 + version=$2 + + try + ( + echo "Uncompressing and installing '$sourceFile'" + xzcat < "$sourceFile" | (cd /Applications/ && sudo cpio -dmi) || throw $ExceptionCPIO + + echo "Accept license" + sudo xcodebuild -license accept || throw $ExceptionAcceptLicense + + echo "Enabling developer mode, so that using lldb does not require interactive password entry" + sudo /usr/sbin/DevToolsSecurity -enable || throw $ExceptionDeveloperMode + + echo "Xcode = $version" >> ~/versions.txt + ) + catch || { + case $ex_code in + $ExceptionCPIO) + echo "Failed to unarchive .cpio." + exit 1; + ;; + $ExceptionDeveloperMode) + echo "Failed to enable developer mode." + exit 1; + ;; + $ExceptionAcceptLicense) + echo "Failed to accept license." + exit 1; + ;; + + esac + } + +} + diff --git a/coin/provisioning/common/macos/pip.sh b/coin/provisioning/common/macos/pip.sh new file mode 100755 index 00000000..c9af5fbc --- /dev/null +++ b/coin/provisioning/common/macos/pip.sh @@ -0,0 +1,5 @@ +#!/usr/bin/env bash +# Will install pip utility for python +curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py +sudo python get-pip.py +rm get-pip.py diff --git a/coin/provisioning/common/macos/python3.sh b/coin/provisioning/common/macos/python3.sh new file mode 100755 index 00000000..fc20aa2d --- /dev/null +++ b/coin/provisioning/common/macos/python3.sh @@ -0,0 +1,52 @@ +#!/usr/bin/env bash + +############################################################################# +## +## Copyright (C) 2017 The Qt Company Ltd. +## Copyright (C) 2017 Pelagicore AG +## Contact: http://www.qt.io/licensing/ +## +## This file is part of the provisioning scripts of the Qt Toolkit. +## +## $QT_BEGIN_LICENSE:LGPL21$ +## Commercial License Usage +## Licensees holding valid commercial Qt licenses may use this file in +## accordance with the commercial license agreement provided with the +## Software or, alternatively, in accordance with the terms contained in +## a written agreement between you and The Qt Company. For licensing terms +## and conditions see http://www.qt.io/terms-conditions. For further +## information use the contact form at http://www.qt.io/contact-us. +## +## GNU Lesser General Public License Usage +## Alternatively, this file may be used under the terms of the GNU Lesser +## General Public License version 2.1 or version 3 as published by the Free +## Software Foundation and appearing in the file LICENSE.LGPLv21 and +## LICENSE.LGPLv3 included in the packaging of this file. Please review the +## following information to ensure the GNU Lesser General Public License +## requirements will be met: https://www.gnu.org/licenses/lgpl.html and +## http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +## +## As a special exception, The Qt Company gives you certain additional +## rights. These rights are described in The Qt Company LGPL Exception +## version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +## +## $QT_END_LICENSE$ +## +############################################################################# + +# This script installs python3 + +source "${BASH_SOURCE%/*}/InstallPKGFromURL.sh" + +PrimaryUrl="http://ci-files01-hki.intra.qt.io/input/mac/python-3.6.1-macosx10.6.pkg" +AltUrl="https://www.python.org/ftp/python/3.6.1/python-3.6.1-macosx10.6.pkg" +SHA1="ae0c749544c2d573c3cc29c4c2d7d9a595db28f9" +DestDir="/" + +InstallPKGFromURL "$PrimaryUrl" "$AltUrl" "$SHA1" "$DestDir" + +/Library/Frameworks/Python.framework/Versions/3.6/bin/pip3 install virtualenv + +echo "export PYTHON3_PATH=/Library/Frameworks/Python.framework/Versions/3.6/bin" >> ~/.bashrc +echo "export PIP3_PATH=/Library/Frameworks/Python.framework/Versions/3.6/bin" >> ~/.bashrc +echo "python3 = 3.6.1" >> ~/versions.txt diff --git a/coin/provisioning/common/macos/system_updates.sh b/coin/provisioning/common/macos/system_updates.sh new file mode 100755 index 00000000..0736d740 --- /dev/null +++ b/coin/provisioning/common/macos/system_updates.sh @@ -0,0 +1,40 @@ +#!/usr/bin/env bash + +############################################################################# +## +## Copyright (C) 2017 The Qt Company Ltd. +## Contact: http://www.qt.io/licensing/ +## +## This file is part of the provisioning scripts of the Qt Toolkit. +## +## $QT_BEGIN_LICENSE:LGPL21$ +## Commercial License Usage +## Licensees holding valid commercial Qt licenses may use this file in +## accordance with the commercial license agreement provided with the +## Software or, alternatively, in accordance with the terms contained in +## a written agreement between you and The Qt Company. For licensing terms +## and conditions see http://www.qt.io/terms-conditions. For further +## information use the contact form at http://www.qt.io/contact-us. +## +## GNU Lesser General Public License Usage +## Alternatively, this file may be used under the terms of the GNU Lesser +## General Public License version 2.1 or version 3 as published by the Free +## Software Foundation and appearing in the file LICENSE.LGPLv21 and +## LICENSE.LGPLv3 included in the packaging of this file. Please review the +## following information to ensure the GNU Lesser General Public License +## requirements will be met: https://www.gnu.org/licenses/lgpl.html and +## http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +## +## As a special exception, The Qt Company gives you certain additional +## rights. These rights are described in The Qt Company LGPL Exception +## version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +## +## $QT_END_LICENSE$ +## +############################################################################# + +# Disable "Download newly available updates in the background" from App Store +sudo defaults write /Library/Preferences/com.apple.SoftwareUpdate AutomaticDownload -boolean FALSE + +# Disable "Install system data files and security updates" from App Store +sudo defaults write /Library/Preferences/com.apple.SoftwareUpdate CriticalUpdateInstall -boolean FALSE diff --git a/coin/provisioning/common/macos/virtualenv.sh b/coin/provisioning/common/macos/virtualenv.sh new file mode 100755 index 00000000..b6a9a796 --- /dev/null +++ b/coin/provisioning/common/macos/virtualenv.sh @@ -0,0 +1,3 @@ +#!/usr/bin/env bash +# Will install virtual env for python +sudo pip install virtualenv |