mirror of
https://github.com/miurahr/aqtinstall.git
synced 2025-12-17 04:34:37 +03:00
CI: refactor azure pipelines scripts (#250)
* CI: refactoring Azure pipeline scripts Signed-off-by: Hiroshi Miura <miurahr@linux.com> * CI: azure (wip) Signed-off-by: Hiroshi Miura <miurahr@linux.com> * Add list command Signed-off-by: Hiroshi Miura <miurahr@linux.com> * CI: skip installation of package when install command(linux) Signed-off-by: Hiroshi Miura <miurahr@linux.com> * fix typo Signed-off-by: Hiroshi Miura <miurahr@linux.com>
This commit is contained in:
@@ -57,74 +57,3 @@ jobs:
|
||||
matrix: $[ dependencies.MatricesGenerator.outputs['mtrx.linux'] ]
|
||||
steps:
|
||||
- template: ci/steps.yml
|
||||
|
||||
- job: LinuxSpecificMirror
|
||||
displayName: Linux (Specific Mirror)
|
||||
variables:
|
||||
PYTHON_VERSION: '3.8'
|
||||
QT_VERSION: 6.1.0
|
||||
HOST: linux
|
||||
TARGET: desktop
|
||||
ARCH: gcc_64
|
||||
ARCHDIR: gcc_64
|
||||
QT_BASE_MIRROR: http://mirrors.ocf.berkeley.edu/qt/
|
||||
pool:
|
||||
vmImage: 'ubuntu-20.04'
|
||||
steps:
|
||||
- template: ci/steps.yml
|
||||
|
||||
- job: LinuxSubArchives
|
||||
displayName: Linux (subarchive spcified)
|
||||
variables:
|
||||
PYTHON_VERSION: '3.8'
|
||||
QT_VERSION: 5.15.0
|
||||
HOST: linux
|
||||
TARGET: desktop
|
||||
ARCH: gcc_64
|
||||
ARCHDIR: gcc_64
|
||||
SUBARCHIVES: qtbase qttools qt icu
|
||||
pool:
|
||||
vmImage: 'ubuntu-18.04'
|
||||
steps:
|
||||
- template: ci/steps.yml
|
||||
|
||||
- job: LinuxSrc
|
||||
displayName: Linux (source)
|
||||
variables:
|
||||
PYTHON_VERSION: '3.8'
|
||||
QT_VERSION: 6.1.0
|
||||
HOST: linux
|
||||
TARGET: desktop
|
||||
TOOL_NAME: src
|
||||
SUBARCHIVES: qt
|
||||
pool:
|
||||
vmImage: 'ubuntu-18.04'
|
||||
steps:
|
||||
- template: ci/steps.yml
|
||||
|
||||
- job: LinuxExamples
|
||||
displayName: Linux (Examples)
|
||||
variables:
|
||||
PYTHON_VERSION: '3.8'
|
||||
QT_VERSION: 5.15.0
|
||||
HOST: linux
|
||||
TARGET: desktop
|
||||
TOOL_NAME: examples
|
||||
pool:
|
||||
vmImage: 'ubuntu-18.04'
|
||||
steps:
|
||||
- template: ci/steps.yml
|
||||
|
||||
- job: LinuxDoc
|
||||
displayName: Linux (doc)
|
||||
variables:
|
||||
PYTHON_VERSION: '3.8'
|
||||
QT_VERSION: 5.15.0
|
||||
HOST: linux
|
||||
TARGET: desktop
|
||||
TOOL_NAME: doc
|
||||
SUBARCHIVES: qtdoc
|
||||
pool:
|
||||
vmImage: 'ubuntu-18.04'
|
||||
steps:
|
||||
- template: ci/steps.yml
|
||||
|
||||
@@ -5,15 +5,20 @@ import collections
|
||||
import json
|
||||
from itertools import product
|
||||
|
||||
MIRROR = "http://mirrors.ocf.berkeley.edu/qt/"
|
||||
|
||||
|
||||
class BuildJob:
|
||||
def __init__(self, qt_version, host, target, arch, archdir, module=None):
|
||||
def __init__(self, command, qt_version, host, target, arch, archdir, *, module=None, mirror=None, subarchives=None):
|
||||
self.command = command
|
||||
self.qt_version = qt_version
|
||||
self.host = host
|
||||
self.target = target
|
||||
self.arch = arch
|
||||
self.archdir = archdir
|
||||
self.module = module
|
||||
self.mirror = mirror
|
||||
self.subarchives = subarchives
|
||||
|
||||
|
||||
class PlatformBuildJobs:
|
||||
@@ -44,57 +49,62 @@ all_platform_build_jobs = [
|
||||
# Linux Desktop
|
||||
for qt_version in qt_versions:
|
||||
linux_build_jobs.append(
|
||||
BuildJob(qt_version, 'linux', 'desktop', 'gcc_64', 'gcc_64')
|
||||
BuildJob('install', qt_version, 'linux', 'desktop', 'gcc_64', 'gcc_64')
|
||||
)
|
||||
|
||||
# Mac Desktop
|
||||
for qt_version in qt_versions:
|
||||
mac_build_jobs.append(
|
||||
BuildJob(qt_version, 'mac', 'desktop', 'clang_64', "clang_64")
|
||||
BuildJob('install', qt_version, 'mac', 'desktop', 'clang_64', "clang_64")
|
||||
)
|
||||
|
||||
# Windows Desktop
|
||||
windows_build_jobs.extend(
|
||||
[
|
||||
BuildJob('5.14.2', 'windows', 'desktop', 'win64_msvc2017_64', 'msvc2017_64'),
|
||||
BuildJob('5.14.2', 'windows', 'desktop', 'win32_msvc2017', 'msvc2017'),
|
||||
BuildJob('5.13.2', 'windows', 'desktop', 'win64_msvc2015_64', 'msvc2015_64'),
|
||||
BuildJob('5.15.2', 'windows', 'desktop', 'win64_mingw81', 'mingw81_64'),
|
||||
BuildJob('install', '5.14.2', 'windows', 'desktop', 'win64_msvc2017_64', 'msvc2017_64', mirror=MIRROR),
|
||||
BuildJob('install', '5.14.2', 'windows', 'desktop', 'win32_msvc2017', 'msvc2017', mirror=MIRROR),
|
||||
BuildJob('install', '5.13.2', 'windows', 'desktop', 'win64_msvc2015_64', 'msvc2015_64', mirror=MIRROR),
|
||||
BuildJob('install', '5.15.2', 'windows', 'desktop', 'win64_mingw81', 'mingw81_64', mirror=MIRROR),
|
||||
# Known issue with Azure-Pipelines environment: it has a pre-installed mingw81 which cause link error.
|
||||
# BuildJob('5.15.0', 'windows', 'desktop', 'win32_mingw81', 'mingw81_32'),
|
||||
BuildJob('5.15.2', 'windows', 'desktop', 'win64_msvc2019_64', 'msvc2019_64', module='qcharts qtnetworkauth'),
|
||||
# BuildJob('install', '5.15.0', 'windows', 'desktop', 'win32_mingw81', 'mingw81_32', mirror=MIRROR),
|
||||
BuildJob('install', '5.15.2', 'windows', 'desktop', 'win64_msvc2019_64', 'msvc2019_64', module='qcharts qtnetworkauth', mirror=MIRROR),
|
||||
]
|
||||
)
|
||||
|
||||
# Extra modules test
|
||||
linux_build_jobs.extend(
|
||||
[
|
||||
BuildJob('5.15.2', 'linux', 'desktop', 'gcc_64', 'gcc_64', module='qcharts qtnetworkauth'),
|
||||
BuildJob('5.14.2', 'linux', 'desktop', 'gcc_64', 'gcc_64', module='all')
|
||||
BuildJob('install', '5.15.2', 'linux', 'desktop', 'gcc_64', 'gcc_64', module='qcharts qtnetworkauth'),
|
||||
BuildJob('install', '5.14.2', 'linux', 'desktop', 'gcc_64', 'gcc_64', module='all'),
|
||||
BuildJob('install', '5.15.2', 'linux', 'desktop', 'gcc_64', 'gcc_64', subarchives='qtbase qttools qt icu'),
|
||||
BuildJob('src', '6.1.0', 'linux', 'desktop', 'gcc_64', 'gcc_64', subarchives='qt'),
|
||||
BuildJob('doc', '6.1.0', 'linux', 'desktop', 'gcc_64', 'gcc_64', subarchives='qtdoc'),
|
||||
# test for list commands
|
||||
BuildJob('list', '6.1.0', 'linux', 'desktop', '', '')
|
||||
]
|
||||
)
|
||||
mac_build_jobs.append(
|
||||
BuildJob('5.14.2', 'mac', 'desktop', 'clang_64', 'clang_64', module='qcharts qtnetworkauth')
|
||||
BuildJob('install', '5.14.2', 'mac', 'desktop', 'clang_64', 'clang_64', module='qcharts qtnetworkauth')
|
||||
)
|
||||
|
||||
# WASM
|
||||
linux_build_jobs.append(
|
||||
BuildJob('5.14.2', 'linux', 'desktop', 'wasm_32', "wasm_32")
|
||||
BuildJob('install', '5.14.2', 'linux', 'desktop', 'wasm_32', "wasm_32")
|
||||
)
|
||||
mac_build_jobs.append(
|
||||
BuildJob('5.14.2', 'mac', 'desktop', 'wasm_32', "wasm_32")
|
||||
BuildJob('install', '5.14.2', 'mac', 'desktop', 'wasm_32', "wasm_32")
|
||||
)
|
||||
|
||||
# mobile SDK
|
||||
mac_build_jobs.extend(
|
||||
[
|
||||
BuildJob('5.15.2', 'mac', 'ios', 'ios', 'ios'),
|
||||
BuildJob('6.1.0', 'mac', 'android', 'android_armv7', 'android_armv7')
|
||||
BuildJob('install', '5.15.2', 'mac', 'ios', 'ios', 'ios'),
|
||||
BuildJob('install', '6.1.0', 'mac', 'android', 'android_armv7', 'android_armv7')
|
||||
]
|
||||
)
|
||||
linux_build_jobs.extend(
|
||||
[
|
||||
BuildJob('6.1.0', 'linux', 'android', 'android_armv7', 'android_armv7')
|
||||
BuildJob('install', '6.1.0', 'linux', 'android', 'android_armv7', 'android_armv7')
|
||||
]
|
||||
)
|
||||
|
||||
@@ -104,20 +114,24 @@ for platform_build_job in all_platform_build_jobs:
|
||||
matrix_dictionary = collections.OrderedDict()
|
||||
|
||||
for build_job, python_version in product(platform_build_job.build_jobs, python_versions):
|
||||
key = '{} {} for {} on {}'.format(build_job.qt_version, build_job.arch, build_job.target, build_job.host)
|
||||
key = '{} {} {} for {}'.format(build_job.command, build_job.qt_version, build_job.arch, build_job.target)
|
||||
if build_job.module:
|
||||
key = "{} ({})".format(key, build_job.module)
|
||||
if build_job.subarchives:
|
||||
key = "{} ({})".format(key, build_job.subarchives)
|
||||
matrix_dictionary[key] = collections.OrderedDict(
|
||||
[
|
||||
('PYTHON_VERSION', python_version),
|
||||
('SUBCOMMAND', build_job.command),
|
||||
('QT_VERSION', build_job.qt_version),
|
||||
('HOST', build_job.host),
|
||||
('TARGET', build_job.target),
|
||||
('ARCH', build_job.arch),
|
||||
('ARCHDIR', build_job.archdir),
|
||||
('MODULE', build_job.module if build_job.module else ''),
|
||||
("QT_BASE_MIRROR", "http://mirrors.ocf.berkeley.edu/qt/" if platform_build_job.platform == "windows" else "")
|
||||
]
|
||||
("QT_BASE_MIRROR", build_job.mirror if build_job.mirror else ''),
|
||||
("SUBARCHIVES", build_job.subarchives if build_job.subarchives else '')
|
||||
]
|
||||
)
|
||||
|
||||
matrices[platform_build_job.platform] = matrix_dictionary
|
||||
|
||||
241
ci/steps.yml
241
ci/steps.yml
@@ -12,131 +12,58 @@ steps:
|
||||
## we insert sleep in random duration < 30sec to reduce
|
||||
## download server load.
|
||||
- bash: |
|
||||
set -e
|
||||
number=$RANDOM
|
||||
let "number %= 30"
|
||||
sleep $number
|
||||
mkdir Qt
|
||||
cd Qt
|
||||
python -m aqt install $(QT_VERSION) $(HOST) $(TARGET) $(ARCH)
|
||||
if [[ "$(TARGET)" == "android" || "$(TARGET)" == "ios" ]]; then
|
||||
python -m aqt install $(QT_VERSION) $(HOST) desktop --archives qtbase
|
||||
if [[ "$(SUBCOMMAND)" == "install" ]]; then
|
||||
opt=""
|
||||
if [[ "$(QT_BASE_MIRROR)" != "" ]]; then
|
||||
opt+=" -b $(QT_BASE_MIRROR)"
|
||||
fi
|
||||
if [[ "$(MODULE)" != "" ]]; then
|
||||
opt+=" -m $(MODULE)"
|
||||
fi
|
||||
if [[ "$(SUBARCHIVES)" != "" ]]; then
|
||||
opt+=" --archives $(SUBARCHIVES)"
|
||||
fi
|
||||
python -m aqt install $(QT_VERSION) $(HOST) $(TARGET) $(ARCH) $opt
|
||||
if [[ "$(TARGET)" == "android" || "$(TARGET)" == "ios" ]]; then
|
||||
if [[ "$(HOST)" == "windows" ]]; then
|
||||
python -m aqt install $(QT_VERSION) $(HOST) desktop mingw81_64 --archives qtbase
|
||||
else
|
||||
python -m aqt install $(QT_VERSION) $(HOST) desktop --archives qtbase
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
if [[ "$(SUBCOMMAND)" == "list" ]]; then
|
||||
echo implement me.
|
||||
fi
|
||||
if [[ "$(SUBCOMMAND)" == "src" ]]; then
|
||||
python -m aqt $(SUBCOMMAND) $(QT_VERSION) $(HOST) $(TARGET) --archives $(SUBARCHIVES)
|
||||
fi
|
||||
if [[ "$(SUBCOMMAND)" == "doc" ]]; then
|
||||
python -m aqt $(SUBCOMMAND) $(QT_VERSION) $(HOST) $(TARGET) --archives $(SUBARCHIVES)
|
||||
fi
|
||||
workingDirectory: $(Build.BinariesDirectory)
|
||||
env:
|
||||
AQT_CONFIG: $(Build.SourcesDirectory)/ci/settings.ini
|
||||
condition: and(not(variables['QT_BASE_MIRROR']), not(variables['TOOL_NAME']), not(variables['EXTERNAL']), eq(variables['MODULE'], ''), eq(variables['SUBARCHIVES'], ''), ne( variables['Agent.OS'], 'Windows_NT'))
|
||||
displayName: Run Aqt (No Base URL Set)
|
||||
- powershell: |
|
||||
mkdir Qt
|
||||
Copy-Item -Path "$(Build.SourcesDirectory)\ci\settings.ini" -Destination "Qt"
|
||||
cd Qt
|
||||
python -m aqt -c settings.ini install $(QT_VERSION) $(HOST) $(TARGET) $(ARCH)
|
||||
if ('$(TARGET)' -eq 'android') {
|
||||
python -m aqt -c settings.ini install $(QT_VERSION) $(HOST) desktop mingw81_64 --archives qtbase
|
||||
}
|
||||
workingDirectory: $(Build.BinariesDirectory)
|
||||
condition: and(not(variables['QT_BASE_MIRROR']), not(variables['TOOL_NAME']), not(variables['EXTERNAL']), eq(variables['MODULE'], ''), eq(variables['SUBARCHIVES'], ''), eq( variables['Agent.OS'], 'Windows_NT'))
|
||||
displayName: Run Aqt (No Base URL Set, Windows)
|
||||
- bash: |
|
||||
number=$RANDOM
|
||||
let "number %= 30"
|
||||
sleep $number
|
||||
mkdir Qt
|
||||
cd Qt
|
||||
python -m aqt install $(QT_VERSION) $(HOST) $(TARGET) $(ARCH) -b $(QT_BASE_MIRROR)
|
||||
workingDirectory: $(Build.BinariesDirectory)
|
||||
env:
|
||||
AQT_CONFIG: $(Build.SourcesDirectory)/ci/settings.ini
|
||||
condition: and(variables['QT_BASE_MIRROR'], not(variables['TOOL_NAME']), not(variables['EXTERNAL']), eq(variables['MODULE'], ''), eq(variables['SUBARCHIVES'], ''))
|
||||
displayName: Run Aqt (Base URL Set)
|
||||
- bash: |
|
||||
number=$RANDOM
|
||||
let "number %= 30"
|
||||
sleep $number
|
||||
mkdir Qt
|
||||
cd Qt
|
||||
python -m aqt install $(QT_VERSION) $(HOST) $(TARGET) $(ARCH) -m $(MODULE)
|
||||
workingDirectory: $(Build.BinariesDirectory)
|
||||
env:
|
||||
AQT_CONFIG: $(Build.SourcesDirectory)/ci/settings.ini
|
||||
condition: and(not(variables['TOOL_NAME']), not(variables['EXTERNAL']), ne(variables['MODULE'], ''), eq(variables['SUBARCHIVES'], ''), not(variables['QT_BASE_MIRROR']))
|
||||
displayName: Run Aqt (With modules)
|
||||
- bash: |
|
||||
number=$RANDOM
|
||||
let "number %= 30"
|
||||
sleep $number
|
||||
mkdir Qt
|
||||
cd Qt
|
||||
python -m aqt install $(QT_VERSION) $(HOST) $(TARGET) $(ARCH) -m $(MODULE) -b $(QT_BASE_MIRROR)
|
||||
workingDirectory: $(Build.BinariesDirectory)
|
||||
env:
|
||||
AQT_CONFIG: $(Build.SourcesDirectory)/ci/settings.ini
|
||||
condition: and(not(variables['TOOL_NAME']), not(variables['EXTERNAL']), ne(variables['MODULE'], ''), eq(variables['SUBARCHIVES'], ''), variables['QT_BASE_MIRROR'])
|
||||
displayName: Run Aqt (With modules, mirror)
|
||||
- bash: |
|
||||
number=$RANDOM
|
||||
let "number %= 30"
|
||||
sleep $number
|
||||
mkdir Qt
|
||||
cd Qt
|
||||
python -m aqt install $(QT_VERSION) $(HOST) $(TARGET) $(ARCH) --archives $(SUBARCHIVES)
|
||||
workingDirectory: $(Build.BinariesDirectory)
|
||||
env:
|
||||
AQT_CONFIG: $(Build.SourcesDirectory)/ci/settings.ini
|
||||
condition: and(ne(variables['SUBARCHIVES'], ''), eq(variables['TOOL_NAME'], ''))
|
||||
displayName: Run Aqt (sub arhives option)
|
||||
- bash: |
|
||||
number=$RANDOM
|
||||
let "number %= 30"
|
||||
sleep $number
|
||||
mkdir Qt
|
||||
cd Qt
|
||||
python -m aqt src $(QT_VERSION) $(HOST) $(TARGET) --archives $(SUBARCHIVES)
|
||||
workingDirectory: $(Build.BinariesDirectory)
|
||||
env:
|
||||
AQT_CONFIG: $(Build.SourcesDirectory)/ci/settings.ini
|
||||
condition: eq(variables['TOOL_NAME'], 'src')
|
||||
displayName: Run Aqt (source)
|
||||
- bash: |
|
||||
number=$RANDOM
|
||||
let "number %= 30"
|
||||
sleep $number
|
||||
mkdir Qt
|
||||
cd Qt
|
||||
python -m aqt examples $(QT_VERSION) $(HOST) $(TARGET)
|
||||
workingDirectory: $(Build.BinariesDirectory)
|
||||
env:
|
||||
AQT_CONFIG: $(Build.SourcesDirectory)/ci/settings.ini
|
||||
condition: eq(variables['TOOL_NAME'], 'examples')
|
||||
displayName: Run Aqt (examples)
|
||||
- bash: |
|
||||
number=$RANDOM
|
||||
let "number %= 30"
|
||||
sleep $number
|
||||
mkdir Qt
|
||||
cd Qt
|
||||
python -m aqt doc $(QT_VERSION) $(HOST) $(TARGET) --archives $(SUBARCHIVES)
|
||||
workingDirectory: $(Build.BinariesDirectory)
|
||||
env:
|
||||
AQT_CONFIG: $(Build.SourcesDirectory)/ci/settings.ini
|
||||
condition: eq(variables['TOOL_NAME'], 'doc')
|
||||
displayName: Run Aqt (doc)
|
||||
displayName: Run Aqt
|
||||
|
||||
# Test installation environments
|
||||
##----------------------------------------------------
|
||||
# for Android on linux
|
||||
- script: |
|
||||
wget https://dl.google.com/android/repository/android-ndk-r21e-linux-x86_64.zip
|
||||
unzip android-ndk-r21e-linux-x86_64.zip
|
||||
condition: and(eq(variables['TARGET'], 'android'), eq(variables['Agent.OS'], 'Linux'))
|
||||
displayName: Download and extract Android NDK
|
||||
# for Android on mac
|
||||
- script: |
|
||||
wget https://dl.google.com/android/repository/android-ndk-r21e-darwin-x86_64.zip
|
||||
unzip android-ndk-r21e-darwin-x86_64.zip
|
||||
condition: and(eq(variables['TARGET'], 'android'), eq(variables['Agent.OS'], 'Darwin'))
|
||||
displayName: Download and extract Android NDK
|
||||
# for Android target
|
||||
- bash: |
|
||||
set -e
|
||||
if [[ "$(Agent.OS)" == "Linux" ]]; then
|
||||
wget https://dl.google.com/android/repository/android-ndk-r21e-linux-x86_64.zip
|
||||
unzip android-ndk-r21e-linux-x86_64.zip
|
||||
fi
|
||||
if [[ "$(Agent.OS)" == "Darwin" ]]; then
|
||||
wget https://dl.google.com/android/repository/android-ndk-r21e-darwin-x86_64.zip
|
||||
unzip android-ndk-r21e-darwin-x86_64.zip
|
||||
fi
|
||||
export ANDROID_NDK_ROOT=$(Build.SourcesDirectory)/android-ndk-r21e
|
||||
mkdir $(Build.BinariesDirectory)/tests
|
||||
(cd $(Build.BinariesDirectory)/tests; 7zr x $(Build.SourcesDirectory)/ci/accelbubble.7z)
|
||||
@@ -146,8 +73,13 @@ steps:
|
||||
condition: and(eq(variables['TARGET'], 'android'), or(eq(variables['Agent.OS'], 'Linux'), eq(variables['Agent.OS'], 'Darwin')))
|
||||
displayName: Build accelbubble example application to test for android
|
||||
|
||||
- script: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y libgl1-mesa-dev
|
||||
condition: and(eq(variables['TARGET'], 'desktop'), eq(variables['Agent.OS'], 'Linux'), eq(variables['SUBCOMMAND'], 'install'))
|
||||
displayName: install test dependency for Linux
|
||||
|
||||
##----------------------------------------------------
|
||||
# Test build on Windows/Linux and Mac
|
||||
# determine Windows build system
|
||||
- powershell: |
|
||||
Install-PackageProvider NuGet -Force
|
||||
@@ -178,55 +110,45 @@ steps:
|
||||
unzip jom.zip
|
||||
condition: eq( variables['Agent.OS'], 'Windows_NT')
|
||||
displayName: Detect toolchain for Windows and update PATH
|
||||
- script: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y libgl1-mesa-dev
|
||||
condition: and(eq( variables['TARGET'], 'desktop'), eq(variables['Agent.OS'], 'Linux'), eq(variables['TOOL_NAME'], ''))
|
||||
displayName: install test dependency for Linux
|
||||
|
||||
# no modules
|
||||
# TODO: current PSCX release does not support VSVER 2019
|
||||
- powershell: |
|
||||
Import-VisualStudioVars -VisualStudioVersion $(VSVER) -Architecture $(ARCHITECTURE)
|
||||
$env:Path += ";$(Build.BinariesDirectory)\Qt\$(QT_VERSION)\$(ARCHDIR)\bin"
|
||||
mkdir $(Build.BinariesDirectory)\tests
|
||||
cd $(Build.BinariesDirectory)\tests
|
||||
7z x $(Build.SourcesDirectory)\ci\helloworld.7z
|
||||
cd ..
|
||||
qmake $(Build.BinariesDirectory)\tests\helloworld
|
||||
jom
|
||||
condition: and(eq( variables['Agent.OS'], 'Windows_NT'), eq(variables['TOOLCHAIN'], 'MSVC'), eq(variables['MODULE'], ''), ne(variables['VSVER'], '2019'))
|
||||
displayName: build test with qmake with MSVC w/o extra module
|
||||
- powershell: |
|
||||
python -m aqt tool --outputdir $(Build.BinariesDirectory)/Qt $(HOST) tools_mingw 8.1.0-1-202004170606 qt.tools.win64_mingw810
|
||||
[Environment]::SetEnvironmentVariable("Path", ";$(Build.BinariesDirectory)\Qt\Tools\mingw810_64\bin" + $env:Path, "Machine")
|
||||
condition: and(eq( variables['Agent.OS'], 'Windows_NT'), eq(variables['TOOLCHAIN'], 'MINGW'), eq(variables['ARCH'], 'win64_mingw81'))
|
||||
displayName: Install Mingw81(win64) from Qt distribution and set PATH
|
||||
- powershell: |
|
||||
python -m aqt tool --outputdir $(Build.BinariesDirectory)/Qt $(HOST) tools_mingw 8.1.0-1-202004170606 qt.tools.win32_mingw810
|
||||
[Environment]::SetEnvironmentVariable("Path", ";$(Build.BinariesDirectory)\Qt\Tools\mingw810_32\bin" + $env:Path, "Machine")
|
||||
condition: and(eq( variables['Agent.OS'], 'Windows_NT'), eq(variables['TOOLCHAIN'], 'MINGW'), eq(variables['ARCH'], 'win32_mingw81'))
|
||||
displayName: Install Mingw81(win32) from Qt distribution and set PATH
|
||||
- powershell: |
|
||||
$env:Path = "$(Build.BinariesDirectory)\Qt\Tools\$(ARCHDIR)\bin;$(Build.BinariesDirectory)\Qt\$(QT_VERSION)\$(ARCHDIR)\bin;" + $env:Path
|
||||
mkdir $(Build.BinariesDirectory)\tests
|
||||
cd $(Build.BinariesDirectory)\tests
|
||||
7z x $(Build.SourcesDirectory)\ci\helloworld.7z
|
||||
cd ..
|
||||
qmake $(Build.BinariesDirectory)\tests\helloworld
|
||||
mingw32-make
|
||||
condition: and(eq( variables['Agent.OS'], 'Windows_NT'), eq(variables['TOOLCHAIN'], 'MINGW'), eq(variables['MODULE'], ''))
|
||||
displayName: build test with qmake with MINGW w/o extra module
|
||||
# When no modules
|
||||
- script: |
|
||||
mkdir $(Build.BinariesDirectory)/tests
|
||||
(cd $(Build.BinariesDirectory)/tests; 7zr x $(Build.SourcesDirectory)/ci/helloworld.7z)
|
||||
export PATH=$(Build.BinariesDirectory)/Qt/$(QT_VERSION)/$(ARCHDIR)/bin:$PATH
|
||||
qmake $(Build.BinariesDirectory)/tests/helloworld
|
||||
make
|
||||
condition: and(eq( variables['TARGET'], 'desktop' ), ne( variables['ARCH'], 'wasm_32' ), or(eq(variables['Agent.OS'], 'Linux'), eq(variables['Agent.OS'], 'Darwin')), eq(variables['MODULE'], ''), eq(variables['TOOL_NAME'], ''))
|
||||
condition: and(eq( variables['TARGET'], 'desktop' ), ne( variables['ARCH'], 'wasm_32' ), or(eq(variables['Agent.OS'], 'Linux'), eq(variables['Agent.OS'], 'Darwin')), eq(variables['MODULE'], ''), eq(variables['SUBCOMMAND'], 'install'))
|
||||
displayName: Build test with qmake for Linux and macOS w/o extra module
|
||||
# modules
|
||||
# TODO: current PSCX release does not support VSVER 2019
|
||||
- powershell: |
|
||||
if ( $env:TOOLCHAIN -eq 'MSVC' ) {
|
||||
Import-VisualStudioVars -VisualStudioVersion $(VSVER) -Architecture $(ARCHITECTURE)
|
||||
$env:Path += ";$(Build.BinariesDirectory)\Qt\$(QT_VERSION)\$(ARCHDIR)\bin"
|
||||
mkdir $(Build.BinariesDirectory)\tests
|
||||
cd $(Build.BinariesDirectory)\tests
|
||||
7z x $(Build.SourcesDirectory)\ci\helloworld.7z
|
||||
cd ..
|
||||
qmake $(Build.BinariesDirectory)\tests\helloworld
|
||||
jom
|
||||
} elseif ( $env:TOOLCHAIN -eq 'MINGW' ) {
|
||||
if ( $env:ARCH -eq 'win64_mingw81' ) {
|
||||
python -m aqt tool --outputdir $(Build.BinariesDirectory)/Qt $(HOST) tools_mingw 8.1.0-1-202004170606 qt.tools.win64_mingw810
|
||||
[Environment]::SetEnvironmentVariable("Path", ";$(Build.BinariesDirectory)\Qt\Tools\mingw810_64\bin" + $env:Path, "Machine")
|
||||
} else {
|
||||
python -m aqt tool --outputdir $(Build.BinariesDirectory)/Qt $(HOST) tools_mingw 8.1.0-1-202004170606 qt.tools.win32_mingw810
|
||||
[Environment]::SetEnvironmentVariable("Path", ";$(Build.BinariesDirectory)\Qt\Tools\mingw810_32\bin" + $env:Path, "Machine")
|
||||
}
|
||||
$env:Path = "$(Build.BinariesDirectory)\Qt\Tools\$(ARCHDIR)\bin;$(Build.BinariesDirectory)\Qt\$(QT_VERSION)\$(ARCHDIR)\bin;" + $env:Path
|
||||
mkdir $(Build.BinariesDirectory)\tests
|
||||
cd $(Build.BinariesDirectory)\tests
|
||||
7z x $(Build.SourcesDirectory)\ci\helloworld.7z
|
||||
cd ..
|
||||
qmake $(Build.BinariesDirectory)\tests\helloworld
|
||||
mingw32-make
|
||||
}
|
||||
condition: and(eq( variables['Agent.OS'], 'Windows_NT'), eq(variables['MODULE'], ''))
|
||||
displayName: build test with qmake w/o extra module
|
||||
- powershell: |
|
||||
Import-VisualStudioVars -VisualStudioVersion $(VSVER) -Architecture $(ARCHITECTURE)
|
||||
$env:Path += ";$(Build.BinariesDirectory)\Qt\$(QT_VERSION)\$(ARCHDIR)\bin"
|
||||
@@ -248,12 +170,6 @@ steps:
|
||||
condition: and(eq( variables['TARGET'], 'desktop'), or(eq(variables['Agent.OS'], 'Linux'), eq(variables['Agent.OS'], 'Darwin')), ne(variables['MODULE'], ''))
|
||||
displayName: Build test with qmake for Linux and macOS with extra module
|
||||
|
||||
##----------------------------------------------------
|
||||
# for ios
|
||||
- script: echo Currently not implemented.
|
||||
condition: and(eq(variables['TARGET'], 'ios'), eq(variables['Agent.OS'], 'Darwin'))
|
||||
displayName: Build test with qmake for ios
|
||||
|
||||
##----------------------------------------------------
|
||||
# wasm_32 on linux and mac
|
||||
- script: |
|
||||
@@ -261,10 +177,6 @@ steps:
|
||||
cd emsdk
|
||||
./emsdk install sdk-fastcomp-1.38.27-64bit
|
||||
./emsdk activate --embedded sdk-fastcomp-1.38.27-64bit
|
||||
workingDirectory: $(Build.BinariesDirectory)
|
||||
condition: and(eq( variables['ARCH'], 'wasm_32' ), or(eq(variables['Agent.OS'], 'Linux'), eq(variables['Agent.OS'], 'Darwin')))
|
||||
displayName: 'Install Emscripten SDK'
|
||||
- bash: |
|
||||
source $(Build.BinariesDirectory)/emsdk/emsdk_env.sh
|
||||
mkdir $(Build.BinariesDirectory)/tests
|
||||
(cd $(Build.BinariesDirectory)/tests; 7zr x $(Build.SourcesDirectory)/ci/openglwindow.7z)
|
||||
@@ -274,4 +186,3 @@ steps:
|
||||
workingDirectory: $(Build.BinariesDirectory)
|
||||
condition: and(eq( variables['ARCH'], 'wasm_32' ), or(eq(variables['Agent.OS'], 'Linux'), eq(variables['Agent.OS'], 'Darwin')))
|
||||
displayName: 'Build WebAssembler sample project'
|
||||
|
||||
|
||||
Reference in New Issue
Block a user