Revision control
Copy as Markdown
type: Group
instructions:
# Tell Coin to fetch latest refs of required repos.
- type: UpdateRepo
repos: [kitware/cmake]
# Build outside of qtbase source dir, to avoid REUSE missing license warnings for the built files.
- type: SetBuildDirectory
directory: "{{.AgentWorkingDir}}"
- type: ChangeDirectory
directory: "{{.BuildDir}}"
# This tells the script where to install the custom cmake, and what files the archive will
# contain.
- type: EnvironmentVariable
variableName: QT_CI_CUSTOM_CMAKE_INSTALL_DIR
variableValue: "{{.BuildDir}}/cmake_build/install"
- type: ExecuteCommand
command: "{{.Env.ENV_PREFIX}} cmake -P {{.SourceDir}}/cmake/QtBuildCMakeFromSourcesScript.cmake"
executeCommandArgumentSplitingBehavior: SplitAfterVariableSubstitution
maxTimeInSeconds: 6000
maxTimeBetweenOutput: 1200
userMessageOnFailure: >
Failed to build custom cmake.
- type: UploadArtifact
archiveDirectory: "{{.Env.QT_CI_CUSTOM_CMAKE_INSTALL_DIR}}"
transferType: GenericArtifactWithName
filename: "custom_cmake_{{.Env.TESTED_MODULE_COIN}}.tar.gz"
maxTimeInSeconds: 1200
maxTimeBetweenOutput: 1200
userMessageOnFailure: >
Failed to upload built cmake.
# Prepends the custom cmake binary path to the PATH variable
- type: PrependToEnvironmentVariable
variableName: PATH
variableValue: "{{.Env.QT_CI_CUSTOM_CMAKE_INSTALL_DIR}}/bin:"
disable_if:
condition: property
property: host.os
equals_value: Windows
# On Windows we prepend the drive letter, because the install dir starts without one, and PATH
# env vars usually expect a drive letter.
# E.g. '\Users\qt\work/cmake_build/install\bin'
# This ensures that the cmake executable is found when it is called with as
# `cmake --build .` directly via the go agent process exeuction command.
- type: PrependToEnvironmentVariable
variableName: PATH
variableValue: "C:{{.Env.QT_CI_CUSTOM_CMAKE_INSTALL_DIR}}\\bin;"
enable_if:
condition: property
property: host.os
equals_value: Windows