summaryrefslogtreecommitdiffstats
path: root/coin/provisioning/common/windows
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2019-11-06 14:19:45 +0100
committerLiang Qi <liang.qi@qt.io>2019-11-06 14:19:45 +0100
commit68189ab965784b5f83729e08de5f54965dc7cd32 (patch)
tree5a9bfe72da0ee5b1ae5abca6c4854503efc06840 /coin/provisioning/common/windows
parent98cb5fa96506837f417d6c2cfdb9c6abe3223d52 (diff)
parentd690f84fd40beebcb9891df8bb656973daf55b22 (diff)
Merge remote-tracking branch 'origin/5.13' into 5.14
Conflicts: coin/provisioning/qtci-macos-10.12-x86_64/05-systemsetup.sh Change-Id: Ie9eae2144868cbe4a6c5ff9472c1a0e8fd53ed08
Diffstat (limited to 'coin/provisioning/common/windows')
-rw-r--r--coin/provisioning/common/windows/android-openssl.ps127
-rw-r--r--coin/provisioning/common/windows/cmake.ps16
-rw-r--r--coin/provisioning/common/windows/disable-clean-manager.ps18
-rw-r--r--coin/provisioning/common/windows/install-gnuwin32.ps11
-rw-r--r--coin/provisioning/common/windows/openssl.ps16
-rw-r--r--coin/provisioning/common/windows/squishInstall.ps16
-rw-r--r--coin/provisioning/common/windows/telegraf_password.ps113
7 files changed, 51 insertions, 16 deletions
diff --git a/coin/provisioning/common/windows/android-openssl.ps1 b/coin/provisioning/common/windows/android-openssl.ps1
index fb5c5aab..d1877b64 100644
--- a/coin/provisioning/common/windows/android-openssl.ps1
+++ b/coin/provisioning/common/windows/android-openssl.ps1
@@ -1,6 +1,6 @@
############################################################################
##
-## Copyright (C) 2018 The Qt Company Ltd.
+## Copyright (C) 2019 The Qt Company Ltd.
## Contact: http://www.qt.io/licensing/
##
## This file is part of the provisioning scripts of the Qt Toolkit.
@@ -45,9 +45,9 @@ if (Is64BitWinHost) {
# Msys need to be installed to target machine
# More info and building instructions can be found from http://doc.qt.io/qt-5/opensslsupport.html
-$version = "1.1.1b"
+$version = "1.1.1d"
$zip = Get-DownloadLocation ("openssl-$version.tar.gz")
-$sha1 = "e9710abf5e95c48ebf47991b10cbb48c09dae102"
+$sha1 = "056057782325134b76d1931c48f2c7e6595d7ef4"
$destination = "C:\Utils\openssl-android-master"
# msys unix style paths
@@ -65,8 +65,25 @@ Remove-Item -Path $zip
Write-Host "Configuring OpenSSL $version for Android..."
Push-Location $destination
# $ must be escaped in powershell...
-Start-Process -NoNewWindow -Wait -ErrorAction Stop -FilePath "$msys_bash" -ArgumentList ("-lc", "`"pushd $openssl_path; ANDROID_NDK_HOME=$ndkPath PATH=${cc_path}:`$PATH CC=clang $openssl_path/Configure shared android-arm`"")
-Start-Process -NoNewWindow -Wait -ErrorAction Stop -FilePath "$msys_bash" -ArgumentList ("-lc", "`"pushd $openssl_path; ANDROID_NDK_HOME=$ndkPath PATH=${cc_path}:`$PATH CC=clang make -f $openssl_path/Makefile build_generated`"")
+
+function CheckExitCode {
+
+ param (
+ $p
+ )
+
+ if ($p.ExitCode) {
+ Write-host "Process failed with exit code: $($p.ExitCode)"
+ exit 1
+ }
+}
+
+$configure = Start-Process -NoNewWindow -Wait -PassThru -ErrorAction Stop -FilePath "$msys_bash" -ArgumentList ("-lc", "`"pushd $openssl_path; ANDROID_NDK_HOME=$ndkPath PATH=${cc_path}:`$PATH CC=clang $openssl_path/Configure shared android-arm`"")
+CheckExitCode $configure
+
+$make = Start-Process -NoNewWindow -Wait -PassThru -ErrorAction Stop -FilePath "$msys_bash" -ArgumentList ("-lc", "`"pushd $openssl_path; ANDROID_NDK_HOME=$ndkPath PATH=${cc_path}:`$PATH CC=clang make -f $openssl_path/Makefile build_generated`"")
+CheckExitCode $make
+
Pop-Location
Set-EnvironmentVariable "OPENSSL_ANDROID_HOME" "$destination"
diff --git a/coin/provisioning/common/windows/cmake.ps1 b/coin/provisioning/common/windows/cmake.ps1
index ec84d706..9d3d6aef 100644
--- a/coin/provisioning/common/windows/cmake.ps1
+++ b/coin/provisioning/common/windows/cmake.ps1
@@ -33,8 +33,8 @@
. "$PSScriptRoot\helpers.ps1"
-$majorminorversion = "3.6"
-$version = "3.6.2"
+$majorminorversion = "3.7"
+$version = "3.7.2"
$zip = Get-DownloadLocation ("cmake-" + $version + "-win32-x86.zip")
$officialurl = "https://cmake.org/files/v" + $majorminorversion + "/cmake-" + $version + "-win32-x86.zip"
@@ -44,7 +44,7 @@ Write-Host "Removing old cmake"
Remove-Item "C:\CMake" -Force -Recurse -ErrorAction SilentlyContinue
Download $officialurl $cachedurl $zip
-Verify-Checksum $zip "541F6E7EFD228E46770B8631FFE57097576E4D4E"
+Verify-Checksum $zip "c80c17e858ecfebfaf16fe8af18b174d2600c4e6"
Extract-7Zip $zip C:
$defaultinstallfolder = "C:\cmake-" + $version + "-win32-x86"
diff --git a/coin/provisioning/common/windows/disable-clean-manager.ps1 b/coin/provisioning/common/windows/disable-clean-manager.ps1
new file mode 100644
index 00000000..6d54e137
--- /dev/null
+++ b/coin/provisioning/common/windows/disable-clean-manager.ps1
@@ -0,0 +1,8 @@
+# This script will disable automatic disk cleanup
+
+. "$PSScriptRoot\helpers.ps1"
+
+Run-Executable "reg.exe" "ADD `"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\StorageSense\Parameters\StoragePolicy`" /V 04 /T REG_dWORD /D 0 /F"
+
+# Maintenance task used by the system to launch a silent auto disk cleanup when running low on free disk space.
+DisableSchedulerTask "DiskCleanup\SilentCleanup"
diff --git a/coin/provisioning/common/windows/install-gnuwin32.ps1 b/coin/provisioning/common/windows/install-gnuwin32.ps1
index 99862b3c..6acede79 100644
--- a/coin/provisioning/common/windows/install-gnuwin32.ps1
+++ b/coin/provisioning/common/windows/install-gnuwin32.ps1
@@ -44,3 +44,4 @@ Verify-Checksum "$temp\$zipPackage" "d7a34a385ccde2374b8a2ca3369e5b8a1452c5a5"
Extract-7Zip "$temp\$zipPackage" C:\Utils
Write-Output "$prog qt5 commit sha = 98c4f1bbebfb3cc6d8e031d36fd1da3c19e634fb" >> ~\versions.txt
+Prepend-Path "C:\Utils\gnuwin32\bin"
diff --git a/coin/provisioning/common/windows/openssl.ps1 b/coin/provisioning/common/windows/openssl.ps1
index 2f21db37..891f5db7 100644
--- a/coin/provisioning/common/windows/openssl.ps1
+++ b/coin/provisioning/common/windows/openssl.ps1
@@ -36,7 +36,7 @@
# This script installs OpenSSL $version.
# Both x86 and x64 versions needed when x86 integrations are done on x64 machine
-$version = "1_1_1b"
+$version = "1_1_1d"
$packagex64 = "C:\Windows\Temp\Win64OpenSSL-$version.exe"
$packagex86 = "C:\Windows\Temp\Win32OpenSSL-$version.exe"
@@ -47,7 +47,7 @@ if (Is64BitWinHost) {
$installFolder = "C:\openssl"
$externalUrl = "https://slproweb.com/download/Win64OpenSSL-$version.exe"
$internalUrl = "\\ci-files01-hki.intra.qt.io\provisioning\openssl\Win64OpenSSL-$version.exe"
- $sha1 = "5b50819dd84aa9219e0cad9cdddf78285bdd1bbb"
+ $sha1 = "df9c40e9e82edf693c15302cbc8e8a057857a13c"
Write-Host "Fetching from URL ..."
Download $externalUrl $internalUrl $packagex64
@@ -74,7 +74,7 @@ if (Is64BitWinHost) {
$externalUrl = "https://slproweb.com/download/Win32OpenSSL-$version.exe"
$internalUrl = "\\ci-files01-hki.intra.qt.io\provisioning\openssl\Win32OpenSSL-$version.exe"
-$sha1 = "1ae5ad4fe5dae01dd056274979cce26945c9e86c"
+$sha1 = "5c49ccd3a5d17f63d25fb819963978f50c7966d0"
Write-Host "Fetching from URL ..."
Download $externalUrl $internalUrl $packagex86
diff --git a/coin/provisioning/common/windows/squishInstall.ps1 b/coin/provisioning/common/windows/squishInstall.ps1
index de04d242..2cc45785 100644
--- a/coin/provisioning/common/windows/squishInstall.ps1
+++ b/coin/provisioning/common/windows/squishInstall.ps1
@@ -1,6 +1,6 @@
#############################################################################
##
-## Copyright (C) 2018 The Qt Company Ltd.
+## Copyright (C) 2019 The Qt Company Ltd.
## Contact: http://www.qt.io/licensing/
##
## This file is part of the provisioning scripts of the Qt Toolkit.
@@ -73,7 +73,9 @@ Function DownloadAndInstallSquish {
Write-Host "Fetching from URL $squishUrl"
Copy-Item "$SquishUrl" "$SquishInstaller"
Write-Host "Installing Squish"
- Run-Executable "$SquishInstaller" "$SquishParameters"
+ $stdoutFile = [System.IO.Path]::GetTempFileName()
+ $stderrFile = [System.IO.Path]::GetTempFileName()
+ Start-Process -FilePath "$SquishInstaller" -Wait -ArgumentList $SquishParameters -PassThru -RedirectStandardOutput $stdoutFile -RedirectStandardError $stderrFile | Out-Null
Remove-Item -Path $SquishInstaller
if ("$bit" -eq "win64") {
if ($squishPackage.StartsWith("mingw")) {
diff --git a/coin/provisioning/common/windows/telegraf_password.ps1 b/coin/provisioning/common/windows/telegraf_password.ps1
index 11d04dbc..773ec866 100644
--- a/coin/provisioning/common/windows/telegraf_password.ps1
+++ b/coin/provisioning/common/windows/telegraf_password.ps1
@@ -31,9 +31,16 @@
##
#############################################################################
+$auth_file = "C:\Users\qt\work\influxdb\coin_vms_writer.auth"
+
+# Provisioning should run even without the secrets repository
+if (Test-Path $auth_file) {
+ $auth_content = Get-Content $auth_file
+ $influxdb_password = $auth_content.Substring($auth_content.LastIndexOf(':') + 1)
+ Remove-Item $auth_file
+} else {
+ $influxdb_password = "no_password_provided"
+}
-$colon_file = Get-Content "C:\Users\qt\work\influxdb\coin_vms_writer.auth"
-$influxdb_password = $colon_file.Substring($colon_file.LastIndexOf(':') + 1)
$telegraf_conf = "C:\telegraf-coin.conf"
(Get-Content $telegraf_conf) | ForEach-Object { $_.Replace("COIN_VMS_WRITER_PASS", $influxdb_password) } | Out-File -Encoding UTF8 $telegraf_conf
-Remove-Item "C:\Users\qt\work\influxdb\coin_vms_writer.auth"