aboutsummaryrefslogtreecommitdiffstats
path: root/coin/provisioning/common
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2017-12-14 11:49:07 +0100
committerLiang Qi <liang.qi@qt.io>2017-12-14 11:49:07 +0100
commitdef11da274cc4af1ba15bdc43fe7aac74bb40d49 (patch)
tree65523361f6e2371f135abb0c0b7c40a9f808b05f /coin/provisioning/common
parent44eaaf374a2c4cc0e370f84c561a7aaaa23f4096 (diff)
parenteccfaf1f506ceb46016e385c1a2707461811def2 (diff)
Merge remote-tracking branch 'origin/5.10' into dev
Conflicts: coin/platform_configs/qt5.txt Change-Id: I9ad5a004544bf2f368ee1aaad247c4db3b36b162
Diffstat (limited to 'coin/provisioning/common')
-rw-r--r--coin/provisioning/common/3dstudio_3rdparty.ps12
-rw-r--r--coin/provisioning/common/InstallAppFromCompressedFileFromURL.sh6
-rw-r--r--coin/provisioning/common/InstallFromCompressedFileFromURL.sh6
-rw-r--r--coin/provisioning/common/android_linux.sh124
-rw-r--r--coin/provisioning/common/cmake.ps19
-rwxr-xr-xcoin/provisioning/common/cmake_linux.sh4
-rw-r--r--coin/provisioning/common/disable-ntp.ps12
-rw-r--r--coin/provisioning/common/disable_selinux.sh5
-rwxr-xr-x[-rw-r--r--]coin/provisioning/common/fbx_linux.sh (renamed from coin/provisioning/common/install-java.ps1)54
-rwxr-xr-xcoin/provisioning/common/fbx_macos.sh79
-rw-r--r--coin/provisioning/common/fbx_windows.ps1 (renamed from coin/provisioning/common/01-macos-removethemall.sh)57
-rw-r--r--coin/provisioning/common/helpers.ps15
-rw-r--r--coin/provisioning/common/install-commandlinetools.sh4
-rw-r--r--coin/provisioning/common/install-jdk.ps178
-rw-r--r--coin/provisioning/common/install-sevenzip.ps114
-rwxr-xr-x[-rw-r--r--]coin/provisioning/common/integrity.sh (renamed from coin/provisioning/common/windows_removethemall.ps1)48
-rw-r--r--coin/provisioning/common/mesa_llvmpipe.ps12
-rw-r--r--coin/provisioning/common/mysql.ps15
-rw-r--r--coin/provisioning/common/ninja.ps15
-rw-r--r--coin/provisioning/common/openssl_for_android_linux.sh85
-rw-r--r--coin/provisioning/common/postgresql.ps15
-rw-r--r--coin/provisioning/common/python3.ps14
-rwxr-xr-xcoin/provisioning/common/python3.sh2
-rw-r--r--[-rwxr-xr-x]coin/provisioning/common/qnx_700.sh (renamed from coin/provisioning/common/linux-removethemall.sh)34
-rw-r--r--coin/provisioning/common/ruby.ps12
-rw-r--r--coin/provisioning/common/vc_redist.ps14
26 files changed, 525 insertions, 120 deletions
diff --git a/coin/provisioning/common/3dstudio_3rdparty.ps1 b/coin/provisioning/common/3dstudio_3rdparty.ps1
index 36816438..f9c8faa7 100644
--- a/coin/provisioning/common/3dstudio_3rdparty.ps1
+++ b/coin/provisioning/common/3dstudio_3rdparty.ps1
@@ -2,7 +2,7 @@
$zip = "c:\users\qt\downloads\Qt3DStudio-3rdparty-win64-CI.zip"
-Invoke-WebRequest -UseBasicParsing http://ci-files01-hki.ci.local/input/3rdparty/Qt3DStudio-3rdparty-win64-CI.zip -OutFile $zip
+Invoke-WebRequest -UseBasicParsing http://ci-files01-hki.intra.qt.io/input/3rdparty/Qt3DStudio-3rdparty-win64-CI.zip -OutFile $zip
Verify-Checksum $zip "08D740D2EFB4CBCDE7D012908B89AA48DE5CD4E1"
Extract-Zip $zip C:\Utils\Qt3DStudio3rdparty
Remove-Item $zip
diff --git a/coin/provisioning/common/InstallAppFromCompressedFileFromURL.sh b/coin/provisioning/common/InstallAppFromCompressedFileFromURL.sh
index bee16dd2..2af2db10 100644
--- a/coin/provisioning/common/InstallAppFromCompressedFileFromURL.sh
+++ b/coin/provisioning/common/InstallAppFromCompressedFileFromURL.sh
@@ -42,6 +42,7 @@ source "${BASH_SOURCE%/*}/try_catch.sh"
# shellcheck source=DownloadURL.sh
source "${BASH_SOURCE%/*}/DownloadURL.sh"
+ExceptionDownload=99
ExceptionCreateTmpFile=100
ExceptionCreateTmpDirectory=101
ExceptionUncompress=102
@@ -80,7 +81,7 @@ function InstallAppFromCompressedFileFromURL {
else
targetDirectory=$(mktemp -d) || throw $ExceptionCreateTmpDirectory
fi
- DownloadURL "$url" "$url_alt" "$expectedSha1" "$targetFile"
+ (DownloadURL "$url" "$url_alt" "$expectedSha1" "$targetFile") || throw $ExceptionDownload
echo "Uncompress $targetFile"
case $extension in
"tar.gz")
@@ -103,6 +104,9 @@ function InstallAppFromCompressedFileFromURL {
catch || {
case $ex_code in
+ $ExceptionDownload)
+ exit 1;
+ ;;
$ExceptionCreateTmpFile)
echo "Failed to create temporary file"
exit 1;
diff --git a/coin/provisioning/common/InstallFromCompressedFileFromURL.sh b/coin/provisioning/common/InstallFromCompressedFileFromURL.sh
index e3716597..df84431a 100644
--- a/coin/provisioning/common/InstallFromCompressedFileFromURL.sh
+++ b/coin/provisioning/common/InstallFromCompressedFileFromURL.sh
@@ -38,6 +38,7 @@ source "${BASH_SOURCE%/*}/try_catch.sh"
# shellcheck source=DownloadURL.sh
source "${BASH_SOURCE%/*}/DownloadURL.sh"
+ExceptionDownload=99
ExceptionCreateTmpFile=100
ExceptionCreateTmpDirectory=101
ExceptionUncompress=102
@@ -66,7 +67,7 @@ function InstallFromCompressedFileFromURL {
echo "Creating temporary file and directory"
targetFile=$(mktemp "$TMPDIR$(uuidgen)XXXXX.$extension") || throw $ExceptionCreateTmpFile
targetDirectory=$(mktemp -d) || throw $ExceptionCreateTmpDirectory
- DownloadURL "$url" "$url_alt" "$expectedSha1" "$targetFile"
+ (DownloadURL "$url" "$url_alt" "$expectedSha1" "$targetFile") || throw $ExceptionDownload
echo "Uncompress $targetFile"
case $extension in
"tar.gz")
@@ -90,6 +91,9 @@ function InstallFromCompressedFileFromURL {
catch || {
case $ex_code in
+ $ExceptionDownload)
+ exit 1;
+ ;;
$ExceptionCreateTmpFile)
echo "Failed to create temporary file"
exit 1;
diff --git a/coin/provisioning/common/android_linux.sh b/coin/provisioning/common/android_linux.sh
new file mode 100644
index 00000000..ee3008c1
--- /dev/null
+++ b/coin/provisioning/common/android_linux.sh
@@ -0,0 +1,124 @@
+#!/bin/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 install Android sdk and ndk.
+
+# It also runs update for SDK API, latest SDK tools, latest platform-tools and build-tools version
+
+source "${BASH_SOURCE%/*}/../common/try_catch.sh"
+source "${BASH_SOURCE%/*}/../common/DownloadURL.sh"
+
+targetFolder="/opt/android"
+sdkTargetFolder="$targetFolder/sdk"
+
+basePath="http://ci-files01-hki.intra.qt.io/input/android"
+
+toolsVersion="r25.2.5"
+toolsFile="tools_$toolsVersion-linux.zip"
+ndkVersion="r10e"
+ndkFile="android-ndk-$ndkVersion-linux-x86_64.zip"
+sdkBuildToolsVersion="25.0.2"
+sdkApiLevel="android-21"
+
+toolsSha1="72df3aa1988c0a9003ccdfd7a13a7b8bd0f47fc1"
+ndkSha1="f692681b007071103277f6edc6f91cb5c5494a32"
+
+toolsTargetFile="/tmp/$toolsFile"
+toolsSourceFile="$basePath/$toolsFile"
+ndkTargetFile="/tmp/$ndkFile"
+ndkSourceFile="$basePath/$ndkFile"
+
+ExceptionDownload=99
+ExceptionUnzipTools=100
+ExceptionUnzipNdk=101
+ExceptionRmTools=102
+ExceptionRmNdk=103
+ExceptionSdkManager=104
+
+try
+(
+ (DownloadURL "$toolsSourceFile" "$toolsSourceFile" "$toolsSha1" "$toolsTargetFile") || throw $ExceptionDownload
+ (DownloadURL "$ndkSourceFile" "$ndkSourceFile" "$ndkSha1" "$ndkTargetFile") || throw $ExceptionDownload
+ echo "Unzipping Android NDK to '$targetFolder'"
+ sudo unzip -q "$ndkTargetFile" -d "$targetFolder" || throw $ExceptionUnzipNdk
+ echo "Unzipping Android Tools to '$sdkTargetFolder'"
+ sudo unzip -q "$toolsTargetFile" -d "$sdkTargetFolder" || throw $ExceptionUnzipTools
+ rm "$ndkTargetFile" || throw $ExceptionRmNdk
+ rm "$toolsTargetFile" || throw $ExceptionRmTools
+
+ echo "Changing ownership of Android files."
+ sudo chown -R qt:wheel "$targetFolder"
+
+ echo "Running SDK manager for platforms;$sdkApiLevel, tools, platform-tools and build-tools;$sdkBuildToolsVersion."
+ echo "y" |"$sdkTargetFolder/tools/bin/sdkmanager" "platforms;$sdkApiLevel" "tools" "platform-tools" "build-tools;$sdkBuildToolsVersion" || throw $ExceptionSdkManager
+
+ echo "export ANDROID_SDK_HOME=$sdkTargetFolder" >> ~/.bashrc
+ echo "export ANDROID_NDK_HOME=$targetFolder/android-ndk-$ndkVersion" >> ~/.bashrc
+ echo "export ANDROID_NDK_HOST=linux-x86_64" >> ~/.bashrc
+ echo "export ANDROID_API_VERSION=$sdkApiLevel" >> ~/.bashrc
+
+ echo "Android SDK tools = $toolsVersion" >> ~/versions.txt
+ echo "Android SDK Build Tools = $sdkBuildToolsVersion" >> ~/versions.txt
+ echo "Android SDK API level = $sdkApiLevel" >> ~/versions.txt
+ echo "Android NDK = $ndkVersion" >> ~/versions.txt
+)
+catch || {
+ case $ex_code in
+ $ExceptionDownload)
+ exit 1;
+ ;;
+ $ExceptionUnzipTools)
+ echo "Failed to unzip Android SDK Tools."
+ exit 1;
+ ;;
+ $ExceptionUnzipNdk)
+ echo "Failed to unzip Android NDK."
+ exit 1;
+ ;;
+ $ExceptionRmTools)
+ echo "Failed to remove temporary tools package '$toolsTargetFile'."
+ exit 1;
+ ;;
+ $ExceptionRmNdk)
+ echo "Failed to remove temporary NDK package '$ndkTargetFile'."
+ exit 1;
+ ;;
+ $ExceptionSdkManager)
+ echo "Failed to run sdkmanager."
+ exit 1;
+ ;;
+ esac
+}
+
diff --git a/coin/provisioning/common/cmake.ps1 b/coin/provisioning/common/cmake.ps1
index 8a94dc5d..d7e26556 100644
--- a/coin/provisioning/common/cmake.ps1
+++ b/coin/provisioning/common/cmake.ps1
@@ -40,16 +40,13 @@ $zip = "c:\users\qt\downloads\cmake-" + $version + "-win32-x86.zip"
$officialurl = "https://cmake.org/files/v" + $majorminorversion + "/cmake-" + $version + "-win32-x86.zip"
$cachedurl = "\\ci-files01-hki.intra.qt.io\provisioning\cmake\cmake-" + $version + "-win32-x86.zip"
+echo "Removing old cmake"
+Remove-Item "C:\CMake" -Force -Recurse -ErrorAction SilentlyContinue
+
Download $officialurl $cachedurl $zip
Verify-Checksum $zip "541F6E7EFD228E46770B8631FFE57097576E4D4E"
Extract-Zip $zip C:
-# TODO: Remove line below after all Windows TIER2 VMs are based on vanilla OS
-if((Test-Path -Path "C:\CMake" )){
- try {
- Rename-Item -ErrorAction 'Stop' "C:\CMake" C:\CMake_old
- } catch {}
-}
$defaultinstallfolder = "C:\cmake-" + $version + "-win32-x86"
Rename-Item $defaultinstallfolder C:\CMake
diff --git a/coin/provisioning/common/cmake_linux.sh b/coin/provisioning/common/cmake_linux.sh
index c23cf9b2..701d9081 100755
--- a/coin/provisioning/common/cmake_linux.sh
+++ b/coin/provisioning/common/cmake_linux.sh
@@ -37,8 +37,8 @@
# CMake is needed for autotests that verify that Qt can be built with CMake
-# shellcheck source=../common/InstallFromCompressedFileFromURL.sh
-source "${BASH_SOURCE%/*}/../common/InstallFromCompressedFileFromURL.sh"
+# shellcheck source=InstallFromCompressedFileFromURL.sh
+source "${BASH_SOURCE%/*}/InstallFromCompressedFileFromURL.sh"
version="3.6.2"
PrimaryUrl="http://ci-files01-hki.intra.qt.io/input/cmake/cmake-3.6.2-Linux-x86_64.tar.gz"
diff --git a/coin/provisioning/common/disable-ntp.ps1 b/coin/provisioning/common/disable-ntp.ps1
new file mode 100644
index 00000000..4ec9d1bd
--- /dev/null
+++ b/coin/provisioning/common/disable-ntp.ps1
@@ -0,0 +1,2 @@
+# Disable the NTP from syncing
+w32tm /config /syncfromflags:NO
diff --git a/coin/provisioning/common/disable_selinux.sh b/coin/provisioning/common/disable_selinux.sh
new file mode 100644
index 00000000..30162166
--- /dev/null
+++ b/coin/provisioning/common/disable_selinux.sh
@@ -0,0 +1,5 @@
+# We need to disable selinux while we are overwriting some binaries
+# required by it. If this is not done, ICU provisioning will create
+# template that is not booting.
+
+sudo sed -i s/SELINUX=enforcing/SELINUX=disabled/g /etc/selinux/config
diff --git a/coin/provisioning/common/install-java.ps1 b/coin/provisioning/common/fbx_linux.sh
index 4b9dd097..66d4793b 100644..100755
--- a/coin/provisioning/common/install-java.ps1
+++ b/coin/provisioning/common/fbx_linux.sh
@@ -1,4 +1,6 @@
-############################################################################
+#!/bin/bash
+
+#############################################################################
##
## Copyright (C) 2017 The Qt Company Ltd.
## Contact: http://www.qt.io/licensing/
@@ -31,26 +33,30 @@
##
#############################################################################
-. "$PSScriptRoot\..\common\helpers.ps1"
-
-# This script will install Java RE
-# Official Java RE 7 downloads require Oracle accounts. Using local mirrors only.
-
-$version = "7u7"
-if( (is64bitWinHost) -eq 1 ) {
- $arch = "x64"
- $sha1 = "9af03460c416931bdee18c2dcebff5db50cb8cb3"
-}
-else {
- $arch = "i586"
- $sha1 = "f76b1be20b144b1ee1d1de3255edb0a6b57d0219"
-}
-
-$url_cache = "\\ci-files01-hki.intra.qt.io\provisioning\windows\jre-" + $version + "-windows-" + $arch + ".exe"
-$javaPackage = "C:\Windows\Temp\java-$version.exe"
-
-Copy-Item $url_cache $javaPackage
-cmd /c "$javaPackage /s SPONSORS=0"
-echo "Cleaning $javaPackage.."
-Remove-Item -Recurse -Force "$javaPackage"
-echo "Java = $version $arch" >> ~\versions.txt
+# This script installs FBX SDK
+source "${BASH_SOURCE%/*}/DownloadURL.sh"
+#s script installs FBX SDK
+
+set -e
+tarballName="fbx20161_2_fbxsdk_linux.tar.gz"
+targetFolder="/opt/fbx"
+cachedUrl="http://ci-files01-hki.intra.qt.io/input/fbx/$tarballName"
+officialUrl="http://download.autodesk.com/us/fbx_release_older/2016.1.2/$tarballName"
+sha1="b0a08778de025e2c6e90d6fbdb6531f74a3da605"
+tmpFolder="/tmp"
+targetFile="$tmpFolder/$tarballName"
+installer="$tmpFolder/fbx20161_2_fbxsdk_linux"
+
+DownloadURL "$cachedUrl" "$officialUrl" "$sha1" "$targetFile"
+
+sudo tar -C $tmpFolder -xf "$targetFile"
+sudo mkdir -p $targetFolder
+(echo "yes"; echo "n") | sudo "$installer" -w "$tmpFolder" "$targetFolder"
+
+rm -rf "$targetFile"
+
+# Set env variables
+echo "export FBXSDK=$targetFolder" >> ~/.profile
+
+echo "FBX SDK = 2016.1.2" >> ~/versions.txt
+
diff --git a/coin/provisioning/common/fbx_macos.sh b/coin/provisioning/common/fbx_macos.sh
new file mode 100755
index 00000000..66a2d998
--- /dev/null
+++ b/coin/provisioning/common/fbx_macos.sh
@@ -0,0 +1,79 @@
+#!/bin/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=./try_catch.sh
+source "${BASH_SOURCE%/*}/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/01-macos-removethemall.sh b/coin/provisioning/common/fbx_windows.ps1
index f0e26480..00de579d 100644
--- a/coin/provisioning/common/01-macos-removethemall.sh
+++ b/coin/provisioning/common/fbx_windows.ps1
@@ -1,10 +1,9 @@
-#!/bin/sh
-#############################################################################
+############################################################################
##
-## Copyright (C) 2016 The Qt Company Ltd.
+## 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.
+## This file is part of the provisioning scripts of the Qt Toolkit.
##
## $QT_BEGIN_LICENSE:LGPL21$
## Commercial License Usage
@@ -32,18 +31,38 @@
##
#############################################################################
-function RemoveDir {
- param=$1
-
- if [ ! -d $param ]
- then
- echo "'$param' don't exists"
- else
- echo "Removing $param..."
- sudo rm -fr $param
- fi
-}
-
-# Remove Android
-param="/opt/android"
-RemoveDir $param
+. "$PSScriptRoot\helpers.ps1"
+
+# This script will install FBX SDK
+
+$version = "2016.1.2"
+
+$name = "fbx20161_2_fbxsdk_vs2015_win"
+$packageName = "$name.7z"
+$installerName = "$name.exe"
+$cacheUrl = "\\ci-files01-hki.intra.qt.io\provisioning\fbx\$packageName"
+$sha1 = "3690400625672bef6369bcf90dcde4d78b493b24"
+
+# The executable is an interactive installer only. We can't run it in a script silently.
+# $officialUrl = "http://download.autodesk.com/us/fbx_release_older/2016.1.2/$installerName"
+# This sha is for the executable
+# $sha1 = "54f581c7c19cf5a08cf5e7bc62b8cc7f0617558e"
+
+#$targetFile = "C:\Windows\Temp\$packageName"
+$targetFolder = "C:\Program Files\"
+
+#echo "Downloading '$installerName'"
+#Download $officialUrl $cacheUrl $targetFile
+#Verify-Checksum $targetFile $sha1
+
+echo "Extracting '$cacheUrl'"
+#Extract-7Zip $cacheUrl $targetFolder
+Start-Process -FilePath "C:\Utils\sevenzip\7z.exe" -ArgumentList "x -y `"$cacheUrl`" -o`"$targetFolder`"" -Wait
+
+#Remove-Item -Recurse -Force "$packageName"
+
+echo "Adding environment variables."
+[Environment]::SetEnvironmentVariable("FBXSDK", "$targetFolder\Autodesk\FBX\FBX SDK\2016.1.2", [EnvironmentVariableTarget]::Machine)
+
+echo "FBX SDK = $version" >> ~\versions.txt
+
diff --git a/coin/provisioning/common/helpers.ps1 b/coin/provisioning/common/helpers.ps1
index d901e370..f6a9fd90 100644
--- a/coin/provisioning/common/helpers.ps1
+++ b/coin/provisioning/common/helpers.ps1
@@ -28,7 +28,10 @@ function Extract-7Zip
if (-not (test-path $zipExe)) {
$zipExe = join-path ${env:ProgramW6432} '7-zip\7z.exe'
if (-not (test-path $zipExe)) {
- throw "Could not find 7-zip."
+ $zipExe = "C:\Utils\sevenzip\7z.exe"
+ if (-not (test-path $zipExe)) {
+ throw "Could not find 7-zip."
+ }
}
}
} else {
diff --git a/coin/provisioning/common/install-commandlinetools.sh b/coin/provisioning/common/install-commandlinetools.sh
index fbebdba8..f224d31d 100644
--- a/coin/provisioning/common/install-commandlinetools.sh
+++ b/coin/provisioning/common/install-commandlinetools.sh
@@ -75,11 +75,11 @@ function InstallCommandLineTools {
exit 1;
;;
$ExceptionInstall)
- echo "Failed to mount"
+ echo "Failed to install"
exit 1;
;;
$ExceptionUnmount)
- echo "Failed to mount"
+ echo "Failed to unmount"
exit 1;
esac
diff --git a/coin/provisioning/common/install-jdk.ps1 b/coin/provisioning/common/install-jdk.ps1
new file mode 100644
index 00000000..e4260deb
--- /dev/null
+++ b/coin/provisioning/common/install-jdk.ps1
@@ -0,0 +1,78 @@
+############################################################################
+##
+## 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$
+##
+#############################################################################
+
+. "$PSScriptRoot\..\common\helpers.ps1"
+
+# This script will install Java SE
+
+$installdir = "C:\Program Files\Java\jdk1.8.0_144"
+
+$version = "8u144"
+if( (is64bitWinHost) -eq 1 ) {
+ $arch = "x64"
+ $sha1 = "adb03bc3f4b40bcb3227687860798981d58e1858"
+}
+else {
+ $arch = "i586"
+ $sha1 = "3b9ab95914514eaefd72b815c5d9dd84c8e216fc"
+}
+
+$url_cache = "\\ci-files01-hki.intra.qt.io\provisioning\windows\jdk-" + $version + "-windows-" + $arch + ".exe"
+$official_url = "http://download.oracle.com/otn-pub/java/jdk/8u144-b01/090f390dda5b47b9b721c7dfaa008135/jdk-" + $version + "-windows-" + $arch + ".exe"
+$javaPackage = "C:\Windows\Temp\jdk-$version.exe"
+
+echo "Fetching Java SE $version..."
+$ProgressPreference = 'SilentlyContinue'
+try {
+ echo "...from local cache"
+ Invoke-WebRequest -UseBasicParsing $url_cache -OutFile $javaPackage
+} catch {
+ echo "...from oracle.com"
+ $client = new-object System.Net.WebClient
+ $cookie = "oraclelicense=accept-securebackup-cookie"
+ $client.Headers.Add("Cookie", $cookie)
+ $client.DownloadFile($official_url, $javaPackage)
+
+ Invoke-WebRequest -UseBasicParsing $official_url -OutFile $javaPackage
+}
+
+Verify-Checksum $javaPackage $sha1
+
+cmd /c "$javaPackage /s SPONSORS=0"
+echo "Cleaning $javaPackage.."
+Remove-Item -Recurse -Force "$javaPackage"
+
+[Environment]::SetEnvironmentVariable("JAVA_HOME", "$installdir", [EnvironmentVariableTarget]::Machine)
+Add-Path "$installdir\bin"
+
+echo "Java SE = $version $arch" >> ~\versions.txt
diff --git a/coin/provisioning/common/install-sevenzip.ps1 b/coin/provisioning/common/install-sevenzip.ps1
index 1db41cc1..5f19543f 100644
--- a/coin/provisioning/common/install-sevenzip.ps1
+++ b/coin/provisioning/common/install-sevenzip.ps1
@@ -35,7 +35,8 @@
# This script installs 7-Zip
-$version = "1604"
+$version = "16.04"
+$nonDottedVersion = "1604"
if( (is64bitWinHost) -eq 1 ) {
$arch = "-x64"
@@ -46,15 +47,18 @@ else {
$sha1 = "dd1cb1163c5572951c9cd27f5a8dd550b33c58a4"
}
-$url_cache = "\\ci-files01-hki.intra.qt.io\provisioning\windows\7z" + $version + $arch + ".exe"
-$url_official = "http://www.7-zip.org/a/7z" + $version + $arch + ".exe"
-$7zPackage = "C:\Windows\Temp\7zip-$version.exe"
+$url_cache = "\\ci-files01-hki.intra.qt.io\provisioning\windows\7z" + $nonDottedVersion + $arch + ".exe"
+$url_official = "http://www.7-zip.org/a/7z" + $nonDottedVersion + $arch + ".exe"
+$7zPackage = "C:\Windows\Temp\7zip-$nonDottedVersion.exe"
+$7zTargetLocation = "C:\Utils\sevenzip\"
Download $url_official $url_cache $7zPackage
Verify-Checksum $7zPackage $sha1
-cmd /c "$7zPackage /S /D=C:\Utils\sevenzip\"
+Start-Process -FilePath $7zPackage -ArgumentList "/S","/D=$7zTargetLocation" -Wait
echo "Cleaning $7zPackage.."
Remove-Item -Recurse -Force "$7zPackage"
+Add-Path $7zTargetLocation
+
echo "7-Zip = $version" >> ~\versions.txt
diff --git a/coin/provisioning/common/windows_removethemall.ps1 b/coin/provisioning/common/integrity.sh
index 0e584900..6998866a 100644..100755
--- a/coin/provisioning/common/windows_removethemall.ps1
+++ b/coin/provisioning/common/integrity.sh
@@ -1,9 +1,11 @@
+#!/bin/bash
+
#############################################################################
##
-## Copyright (C) 2016 The Qt Company Ltd.
+## 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.
+## This file is part of the provisioning scripts of the Qt Toolkit.
##
## $QT_BEGIN_LICENSE:LGPL21$
## Commercial License Usage
@@ -31,31 +33,23 @@
##
#############################################################################
-Function Remove {
-Param (
- [string]$1
- )
- If (Test-Path $1){
- echo "Remove $1"
- Remove-Item -Recurse -Force $1
- }Else{
- echo "'$1' does not exists or already removed !!"
- }
+# This script installs INTEGRITY
+
+source "${BASH_SOURCE%/*}/../common/InstallFromCompressedFileFromURL.sh"
+
+version="11.4.4"
+PrimaryUrl="http://ci-files01-hki.intra.qt.io/input/integrity/ghs_$version.tar.gz"
+AltUrl="$PrimaryUrl" # we lack an external source for this
+SHA1="4afa3c15e13c91734951b73f6b21388294c5d794"
+targetFolder="/opt/ghs"
+appPrefix=""
-}
+InstallFromCompressedFileFromURL "$PrimaryUrl" "$AltUrl" "$SHA1" "$targetFolder" "$appPrefix"
-Function Remove-Path {
- Param (
- [string]$Path
- )
- echo "Remove $path from Path"
- $name = "Path"
- $value = ([System.Environment]::GetEnvironmentVariable("Path").Split(";") | ? {$_ -ne "$path"}) -join ";"
- $type = "Machine"
- [System.Environment]::SetEnvironmentVariable($name,$value,$type)
-}
+echo "export INTEGRITY_BSP=platform-cortex-a9" >> ~/.bashrc
+echo "export INTEGRITY_PATH=$targetFolder/comp_201654" >> ~/.bashrc
+echo "export INTEGRITY_DIR=$targetFolder/int1144" >> ~/.bashrc
+echo "export INTEGRITY_GL_INC_DIR=\$INTEGRITY_DIR/INTEGRITY-include/Vivante/sdk/inc" >> ~/.bashrc
+echo "export INTEGRITY_GL_LIB_DIR=\$INTEGRITY_DIR/libs/Vivante" >> ~/.bashrc
-# Remove Android sdk and ndk
-dir c:\utils\android* | ForEach { Rename-Item $_ $_"-deleted" }
-[Environment]::SetEnvironmentVariable("ANDROID_NDK_HOME",$null,"User")
-[Environment]::SetEnvironmentVariable("ANDROID_SDK_HOME",$null,"User")
+echo "INTEGRITY = $version" >> ~/versions.txt
diff --git a/coin/provisioning/common/mesa_llvmpipe.ps1 b/coin/provisioning/common/mesa_llvmpipe.ps1
index 7ea0629d..82333034 100644
--- a/coin/provisioning/common/mesa_llvmpipe.ps1
+++ b/coin/provisioning/common/mesa_llvmpipe.ps1
@@ -55,7 +55,7 @@ function Extract-Mesa
}
if ( Test-Path C:\Windows\SysWOW64 ) {
- Extract-Mesa $mesaOpenglUrl_64 $mesaOpenglSha1_64 "C:\Windows\sysnative"
+ Extract-Mesa $mesaOpenglUrl_64 $mesaOpenglSha1_64 "C:\Windows\System32"
Extract-Mesa $mesaOpenglUrl_32 $mesaOpenglSha1_32 "C:\Windows\SysWOW64"
} else {
Extract-Mesa $mesaOpenglUrl_32 $mesaOpenglSha1_32 "C:\Windows\system32"
diff --git a/coin/provisioning/common/mysql.ps1 b/coin/provisioning/common/mysql.ps1
index e300566e..63088861 100644
--- a/coin/provisioning/common/mysql.ps1
+++ b/coin/provisioning/common/mysql.ps1
@@ -57,11 +57,6 @@ function DownloadAndInstall
Remove-Item $package
}
-# Remove any leftovers
-try {
- Rename-Item -ErrorAction 'Stop' c:\utils\my_sql c:\utils\mysql_deleted
-} catch {}
-
if( (is64bitWinHost) -eq 1 ) {
# Install x64 bit version
$architecture = "x64"
diff --git a/coin/provisioning/common/ninja.ps1 b/coin/provisioning/common/ninja.ps1
index 75d74d36..08bf2579 100644
--- a/coin/provisioning/common/ninja.ps1
+++ b/coin/provisioning/common/ninja.ps1
@@ -2,11 +2,10 @@
$zip = "c:\users\qt\downloads\ninja-1.6.0-win-x86.zip"
-Download https://github.com/ninja-build/ninja/releases/download/v1.6.0/ninja-win.zip \\ci-files01-hki.ci.local\provisioning\ninja\ninja-1.6.0-win-x86.zip $zip
+Download https://github.com/ninja-build/ninja/releases/download/v1.6.0/ninja-win.zip \\ci-files01-hki.intra.qt.io\provisioning\ninja\ninja-1.6.0-win-x86.zip $zip
Verify-Checksum $zip "E01093F6533818425F8EFB0843CED7DCAABEA3B2"
Extract-Zip $zip C:\Utils\Ninja
Remove-Item $zip
-$machinePath = [Environment]::GetEnvironmentVariable('Path', [EnvironmentVariableTarget]::Machine)
-[Environment]::SetEnvironmentVariable("Path", $machinePath + ";C:\Utils\Ninja", [EnvironmentVariableTarget]::Machine)
+Add-Path "C:\Utils\Ninja"
diff --git a/coin/provisioning/common/openssl_for_android_linux.sh b/coin/provisioning/common/openssl_for_android_linux.sh
new file mode 100644
index 00000000..70684eaf
--- /dev/null
+++ b/coin/provisioning/common/openssl_for_android_linux.sh
@@ -0,0 +1,85 @@
+#!/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 install OpenSSL from sources.
+# Requires GCC and Perl to be in PATH.
+
+source "${BASH_SOURCE%/*}/try_catch.sh"
+source "${BASH_SOURCE%/*}/DownloadURL.sh"
+
+version="1.0.2g"
+officialUrl="https://www.openssl.org/source/openssl-$version.tar.gz"
+cachedUrl="http://ci-files01-hki.intra.qt.io/input/openssl/openssl-$version.tar.gz"
+targetFile="/tmp/openssl-$version.tar.gz"
+installFolder="/home/qt/"
+sha="36af23887402a5ea4ebef91df8e61654906f58f2"
+# Until every VM doing Linux Android builds have provisioned the env variable
+# OPENSSL_ANDROID_HOME, we can't change the hard coded path that's currently in Coin.
+# QTQAINFRA-1436
+opensslHome="${installFolder}openssl-1.0.2"
+
+ExceptionDownload=99
+ExceptionTar=100
+ExceptionConfig=101
+
+try
+(
+ (DownloadURL "$cachedUrl" "$officialUrl" "$sha" "$targetFile") || throw $ExceptionDownload
+
+ tar -xzf "$targetFile" -C "$installFolder" || throw $ExceptionTar
+ # This rename should be removed once hard coded path from Coin is fixed. (QTQAINFRA-1436)
+ mv "${opensslHome}g" "${opensslHome}"
+ pushd "$opensslHome"
+ perl Configure shared android || throw $ExceptionConfig
+
+ echo "export OPENSSL_ANDROID_HOME=$opensslHome" >> ~/.bashrc
+ echo "OpenSSL for Android = $version" >> ~/versions.txt
+)
+catch || {
+ case $ex_code in
+ $ExceptionDownload)
+ exit 1;
+ ;;
+ $ExceptionTar)
+ echo "Failed to extract $targetFile"
+ exit 1;
+ ;;
+ $ExceptionConfig)
+ echo "Failed to run 'config'."
+ exit 1;
+ ;;
+ esac
+
+}
diff --git a/coin/provisioning/common/postgresql.ps1 b/coin/provisioning/common/postgresql.ps1
index dd5858a3..ca47f078 100644
--- a/coin/provisioning/common/postgresql.ps1
+++ b/coin/provisioning/common/postgresql.ps1
@@ -48,11 +48,6 @@ if( (is64bitWinHost) -eq 1 ) {
$internalUrl = "\\ci-files01-hki.intra.qt.io\provisioning\windows\postgresql-$version-windows-x64-binaries.zip"
$sha1 = "4da0453cdfda335e064d4437cf5bb9d356054cfd"
- # Delete any leftovers
- try {
- Rename-Item -ErrorAction 'Stop' c:\utils\postgresql c:\utils\postgresql-deleted
- } catch {}
-
echo "Fetching from URL ..."
Download $externalUrl $internalUrl $packagex64
Verify-Checksum $packagex64 $sha1
diff --git a/coin/provisioning/common/python3.ps1 b/coin/provisioning/common/python3.ps1
index 3c565874..316b567a 100644
--- a/coin/provisioning/common/python3.ps1
+++ b/coin/provisioning/common/python3.ps1
@@ -46,12 +46,12 @@ $install_path = "C:\Python36"
if ( $archVer -eq 64 ) {
echo "Running in 64 bit system"
$externalUrl = "https://www.python.org/ftp/python/$version/python-$version-amd64.exe"
- $internalUrl = "http://ci-files01-hki.ci.local/input/windows/python-$version-amd64.exe"
+ $internalUrl = "http://ci-files01-hki.intra.qt.io/input/windows/python-$version-amd64.exe"
$sha1 = "bf54252c4065b20f4a111cc39cf5215fb1edccff"
}
else {
$externalUrl = "https://www.python.org/ftp/python/$version/python-$version.exe"
- $internalUrl = "http://ci-files01-hki.ci.local/input/windows/python-$version.exe"
+ $internalUrl = "http://ci-files01-hki.intra.qt.io/input/windows/python-$version.exe"
$sha1 = "76c50b747237a0974126dd8b32ea036dd77b2ad1"
}
diff --git a/coin/provisioning/common/python3.sh b/coin/provisioning/common/python3.sh
index 56e82386..31591339 100755
--- a/coin/provisioning/common/python3.sh
+++ b/coin/provisioning/common/python3.sh
@@ -38,7 +38,7 @@
source "${BASH_SOURCE%/*}/InstallPKGFromURL.sh"
-PrimaryUrl="http://ci-files01-hki.ci.local/input/mac/python-3.6.1-macosx10.6.pkg"
+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="/"
diff --git a/coin/provisioning/common/linux-removethemall.sh b/coin/provisioning/common/qnx_700.sh
index 4386ec74..1f1c0f3f 100755..100644
--- a/coin/provisioning/common/linux-removethemall.sh
+++ b/coin/provisioning/common/qnx_700.sh
@@ -33,17 +33,29 @@
##
#############################################################################
-# This script removes preinstalled sw.
-# NOTE! Make sure that ALL software which are removed here have provision script under platrom folders which calls this script
+# This script installs QNX 7.
-function RemoveDir {
- targetFolder=$1
+set -ex
+targetFolder="/opt/"
+sourceFile="http://ci-files01-hki.intra.qt.io/input/qnx/qnx700.tar.xz"
+sha1="949a87c5f00d0756956cb4b1b3b213ecaeee9113"
+folderName="qnx700"
+targetFile="qnx700.tar.xz"
+wget --tries=5 --waitretry=5 --output-document="$targetFile" "$sourceFile"
+echo "$sha1 $targetFile" | sha1sum --check
+if [ ! -d "$targetFolder" ]; then
+ mkdir -p $targetFolder
+fi
+sudo tar -C $targetFolder -Jxf $targetFile
+sudo chown -R qt:users "$targetFolder"/"$folderName"
- if [ -d "$targetFolder" ]; then
- echo "Removing existing $targetFolder..."
- sudo rm -fr "$targetFolder"
- fi
-}
+# Verify that we have last file in tar
+if [ ! -f $targetFolder/$folderName/qnxsdp-env.sh ]; then
+ echo "Installation failed!"
+ exit -1
+fi
-# Android
-RemoveDir /opt/android
+rm -rf $targetFile
+# Set env variables
+echo "export QNX_700=$targetFolder$folderName" >> ~/.bashrc
+echo "QNX SDP = 7.0.0" >> ~/versions.txt
diff --git a/coin/provisioning/common/ruby.ps1 b/coin/provisioning/common/ruby.ps1
index 343bacfc..f7813c20 100644
--- a/coin/provisioning/common/ruby.ps1
+++ b/coin/provisioning/common/ruby.ps1
@@ -2,6 +2,6 @@
$installer = "c:\users\qt\downloads\rubyinstaller-2.3.1.exe"
-Download https://dl.bintray.com/oneclick/rubyinstaller/rubyinstaller-2.3.1.exe http://ci-files01-hki.ci.local/input/ruby/rubyinstaller-2.3.1.exe $installer
+Download https://dl.bintray.com/oneclick/rubyinstaller/rubyinstaller-2.3.1.exe http://ci-files01-hki.intra.qt.io/input/ruby/rubyinstaller-2.3.1.exe $installer
Verify-Checksum $installer "FF377F6F313849C3B0CD72EEC1EFFA436F0E4A36"
& $installer /DIR=C:\ruby /VERYSILENT
diff --git a/coin/provisioning/common/vc_redist.ps1 b/coin/provisioning/common/vc_redist.ps1
index 4213dde9..4a8376b6 100644
--- a/coin/provisioning/common/vc_redist.ps1
+++ b/coin/provisioning/common/vc_redist.ps1
@@ -43,13 +43,13 @@ if ( $archVer -eq 64 ) {
echo "Running in 64 bit system"
$arch = "x64"
$externalUrl = "https://download.microsoft.com/download/9/3/F/93FCF1E7-E6A4-478B-96E7-D4B285925B00/vc_redist.x64.exe"
- $internalUrl = "http://ci-files01-hki.ci.local/input/windows/vc_redist.x64.exe"
+ $internalUrl = "http://ci-files01-hki.intra.qt.io/input/windows/vc_redist.x64.exe"
$sha1 = "3155cb0f146b927fcc30647c1a904cd162548c8c"
}
else {
$arch = "x86"
$externalUrl = "https://download.microsoft.com/download/9/3/F/93FCF1E7-E6A4-478B-96E7-D4B285925B00/vc_redist.x86.exe"
- $internalUrl = "http://ci-files01-hki.ci.local/input/windows/vc_redist.x86.exe"
+ $internalUrl = "http://ci-files01-hki.intra.qt.io/input/windows/vc_redist.x86.exe"
$sha1 = "bfb74e498c44d3a103ca3aa2831763fb417134d1"
}