Share most common part of module_config.yaml
Change-Id: Ieea5b662e039cff24e26a127b4a3a8610ed588cc Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
This commit is contained in:
parent
88883dbf60
commit
8367a51c6d
22
coin/instructions/call_cmake.yaml
Normal file
22
coin/instructions/call_cmake.yaml
Normal file
@ -0,0 +1,22 @@
|
||||
type: Group
|
||||
instructions:
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} {{.InstallDir}}\\bin\\qt-cmake {{.Env.COIN_CMAKE_ARGS}}"
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to call cmake. Contact Liang then.
|
||||
enable_if:
|
||||
condition: property
|
||||
property: host.os
|
||||
equals_value: Windows
|
||||
- type: ExecuteCommand
|
||||
command: "{{.InstallDir}}/bin/qt-cmake {{.Env.COIN_CMAKE_ARGS}}"
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to call cmake. Contact Liang then.
|
||||
disable_if:
|
||||
condition: property
|
||||
property: host.os
|
||||
equals_value: Windows
|
34
coin/instructions/cmake_build_and_upload_test_artifacts.yaml
Normal file
34
coin/instructions/cmake_build_and_upload_test_artifacts.yaml
Normal file
@ -0,0 +1,34 @@
|
||||
type: Group
|
||||
instructions:
|
||||
- type: ChangeDirectory
|
||||
directory: "{{.SourceDir}}/tests"
|
||||
- type: EnvironmentVariable
|
||||
variableName: COIN_CMAKE_ARGS
|
||||
variableValue: "{{.SourceDir}}\\tests"
|
||||
enable_if:
|
||||
condition: property
|
||||
property: host.os
|
||||
equals_value: Windows
|
||||
- type: EnvironmentVariable
|
||||
variableName: COIN_CMAKE_ARGS
|
||||
variableValue: "{{.SourceDir}}/tests"
|
||||
disable_if:
|
||||
condition: property
|
||||
property: host.os
|
||||
equals_value: Windows
|
||||
- !include "{{qt/qtbase}}/call_cmake.yaml"
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} cmake --build ."
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to build sources. In the current state bug can be everywhere. Contact Liang first.
|
||||
- type: UploadTestArtifact
|
||||
transferType: UploadModuleTestsArtifact
|
||||
archiveDirectory: "{{.SourceDir}}/tests"
|
||||
maxTimeInSeconds: 1200
|
||||
maxTimeBetweenOutput: 1200
|
||||
disable_if:
|
||||
condition: property
|
||||
property: configureArgs
|
||||
contains_value: "-DBUILD_SHARED_LIBS=OFF"
|
46
coin/instructions/cmake_module_build_instructions.yaml
Normal file
46
coin/instructions/cmake_module_build_instructions.yaml
Normal file
@ -0,0 +1,46 @@
|
||||
type: Group
|
||||
instructions:
|
||||
- type: MakeDirectory
|
||||
directory: .git
|
||||
- type: SetBuildDirectory
|
||||
directory: "{{.SourceDir}}"
|
||||
- type: ChangeDirectory
|
||||
directory: "{{.BuildDir}}"
|
||||
- type: EnvironmentVariable
|
||||
variableName: COIN_CMAKE_ARGS
|
||||
variableValue: "-DBUILD_TESTING=OFF {{.SourceDir}}"
|
||||
- !include "{{qt/qtbase}}/call_cmake.yaml"
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} cmake --build ."
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to build sources. In the current state bug can be everywhere. Contact Liang first.
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} cmake --install ."
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to install package.
|
||||
- type: EnvironmentVariable
|
||||
variableName: DESTDIR
|
||||
variableValue: "{{.InstallRoot}}"
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} cmake --install ."
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to install package for archiving.
|
||||
- type: SignPackage
|
||||
enable_if:
|
||||
condition: property
|
||||
property: host.os
|
||||
equals_value: Windows
|
||||
directory: "{{.InstallRoot}}/{{.AgentWorkingDir}}"
|
||||
maxTimeInSeconds: 1200
|
||||
maxTimeBetweenOutput: 1200
|
||||
- type: UploadArtifact
|
||||
archiveDirectory: "{{.InstallRoot}}/{{.AgentWorkingDir}}"
|
||||
transferType: UploadModuleBuildArtifact
|
||||
maxTimeInSeconds: 1200
|
||||
maxTimeBetweenOutput: 1200
|
49
coin/instructions/cmake_qtbase_build_instructions.yaml
Normal file
49
coin/instructions/cmake_qtbase_build_instructions.yaml
Normal file
@ -0,0 +1,49 @@
|
||||
type: Group
|
||||
instructions:
|
||||
- type: MakeDirectory
|
||||
directory: .git
|
||||
- type: SetBuildDirectory
|
||||
directory: "{{.SourceDir}}"
|
||||
- type: ChangeDirectory
|
||||
directory: "{{.BuildDir}}"
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} cmake {{.Env.CONFIGURE_ARGS}} -DCMAKE_INSTALL_PREFIX:PATH={{.InstallDir}} -DBUILD_TESTING=OFF {{.SourceDir}}"
|
||||
executeCommandArgumentSplitingBehavior: SplitAfterVariableSubstitution
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to call cmake. Contact Liang then.
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} cmake --build ."
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to build sources. In the current state bug can be everywhere. Contact Liang first.
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} cmake --install ."
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to install package.
|
||||
- type: EnvironmentVariable
|
||||
variableName: DESTDIR
|
||||
variableValue: "{{.InstallRoot}}"
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} cmake --install ."
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to install package for archiving.
|
||||
- type: SignPackage
|
||||
enable_if:
|
||||
condition: property
|
||||
property: host.os
|
||||
equals_value: Windows
|
||||
directory: "{{.InstallRoot}}/{{.AgentWorkingDir}}"
|
||||
maxTimeInSeconds: 1200
|
||||
maxTimeBetweenOutput: 1200
|
||||
- type: UploadArtifact
|
||||
archiveDirectory: "{{.InstallRoot}}/{{.AgentWorkingDir}}"
|
||||
transferType: UploadModuleBuildArtifact
|
||||
maxTimeInSeconds: 1200
|
||||
maxTimeBetweenOutput: 1200
|
22
coin/instructions/cmake_regular_test_instructions.yaml
Normal file
22
coin/instructions/cmake_regular_test_instructions.yaml
Normal file
@ -0,0 +1,22 @@
|
||||
type: Group
|
||||
instructions:
|
||||
- type: InstallTestBinaryArchive
|
||||
relativeStoragePath: "{{.Env.MODULE_ARTIFACTS_RELATIVE_STORAGE_PATH}}/tests.tar.gz"
|
||||
directory: "{{.SourceDir}}/tests"
|
||||
maxTimeInSeconds: 1200
|
||||
maxTimeBetweenOutput: 1200
|
||||
userMessageOnFailure: >
|
||||
Failed to install tests archive.
|
||||
- type: ChangeDirectory
|
||||
directory: "{{.SourceDir}}/tests"
|
||||
- type: ExecuteCommand
|
||||
command: "ctest -V --rerun-failed"
|
||||
ignoreExitCode: true
|
||||
maxTimeInSeconds: 7200
|
||||
maxTimeBetweenOutput: 900
|
||||
userMessageOnFailure: >
|
||||
Failed to run tests.
|
||||
disable_if:
|
||||
condition: property
|
||||
property: configureArgs
|
||||
contains_value: "-DBUILD_SHARED_LIBS=OFF"
|
@ -4,127 +4,10 @@ accept_configuration:
|
||||
property: host.os
|
||||
equals_property: target.os
|
||||
|
||||
call_cmake_instructions: &call_cmake
|
||||
type: Group
|
||||
instructions:
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} {{.InstallDir}}\\bin\\qt-cmake {{.SourceDir}}/tests"
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to call cmake. Contact Liang then.
|
||||
enable_if:
|
||||
condition: property
|
||||
property: host.os
|
||||
equals_value: Windows
|
||||
- type: ExecuteCommand
|
||||
command: "{{.InstallDir}}/bin/qt-cmake {{.SourceDir}}/tests"
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to call cmake. Contact Liang then.
|
||||
disable_if:
|
||||
condition: property
|
||||
property: host.os
|
||||
equals_value: Windows
|
||||
|
||||
build_and_upload_test_artifacts_instruction: &build_and_upload_test_artifacts
|
||||
type: Group
|
||||
instructions:
|
||||
- type: ChangeDirectory
|
||||
directory: "{{.SourceDir}}/tests"
|
||||
- *call_cmake
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} cmake --build ."
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to build sources. In the current state bug can be everywhere. Contact Liang first.
|
||||
- type: UploadTestArtifact
|
||||
transferType: UploadModuleTestsArtifact
|
||||
archiveDirectory: "{{.SourceDir}}/tests"
|
||||
maxTimeInSeconds: 1200
|
||||
maxTimeBetweenOutput: 1200
|
||||
disable_if:
|
||||
condition: property
|
||||
property: configureArgs
|
||||
contains_value: "-DBUILD_SHARED_LIBS=OFF"
|
||||
|
||||
regular_specific_test_instructions: ®ular_test_instructions
|
||||
type: Group
|
||||
instructions:
|
||||
- type: InstallTestBinaryArchive
|
||||
relativeStoragePath: "{{.Env.MODULE_ARTIFACTS_RELATIVE_STORAGE_PATH}}/tests.tar.gz"
|
||||
directory: "{{.SourceDir}}/tests"
|
||||
maxTimeInSeconds: 1200
|
||||
maxTimeBetweenOutput: 1200
|
||||
userMessageOnFailure: >
|
||||
Failed to install tests archive.
|
||||
- type: ChangeDirectory
|
||||
directory: "{{.SourceDir}}/tests"
|
||||
- type: ExecuteCommand
|
||||
command: "ctest -V --rerun-failed"
|
||||
ignoreExitCode: true
|
||||
maxTimeInSeconds: 7200
|
||||
maxTimeBetweenOutput: 900
|
||||
userMessageOnFailure: >
|
||||
Failed to run tests.
|
||||
disable_if:
|
||||
condition: property
|
||||
property: configureArgs
|
||||
contains_value: "-DBUILD_SHARED_LIBS=OFF"
|
||||
|
||||
|
||||
build_instructions:
|
||||
- type: MakeDirectory
|
||||
directory: .git
|
||||
- type: SetBuildDirectory
|
||||
directory: "{{.SourceDir}}"
|
||||
- type: ChangeDirectory
|
||||
directory: "{{.BuildDir}}"
|
||||
- !include "{{qt/qtbase}}/prepare_building_env.yaml"
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} cmake {{.Env.CONFIGURE_ARGS}} -DCMAKE_INSTALL_PREFIX:PATH={{.InstallDir}} -DBUILD_TESTING=OFF {{.SourceDir}}"
|
||||
executeCommandArgumentSplitingBehavior: SplitAfterVariableSubstitution
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to call cmake. Contact Liang then.
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} cmake --build ."
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to build sources. In the current state bug can be everywhere. Contact Liang first.
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} cmake --install ."
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to install package.
|
||||
- type: EnvironmentVariable
|
||||
variableName: DESTDIR
|
||||
variableValue: "{{.InstallRoot}}"
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.ENV_PREFIX}} cmake --install ."
|
||||
maxTimeInSeconds: 6000
|
||||
maxTimeBetweenOutput: 120
|
||||
userMessageOnFailure: >
|
||||
Failed to install package for archiving.
|
||||
- type: SignPackage
|
||||
enable_if:
|
||||
condition: property
|
||||
property: host.os
|
||||
equals_value: Windows
|
||||
directory: "{{.InstallRoot}}/{{.AgentWorkingDir}}"
|
||||
maxTimeInSeconds: 1200
|
||||
maxTimeBetweenOutput: 1200
|
||||
- type: UploadArtifact
|
||||
archiveDirectory: "{{.InstallRoot}}/{{.AgentWorkingDir}}"
|
||||
transferType: UploadModuleBuildArtifact
|
||||
maxTimeInSeconds: 1200
|
||||
maxTimeBetweenOutput: 1200
|
||||
- *build_and_upload_test_artifacts
|
||||
- !include "{{qt/qtbase}}/cmake_qtbase_build_instructions.yaml"
|
||||
- !include "{{qt/qtbase}}/cmake_build_and_upload_test_artifacts.yaml"
|
||||
|
||||
test_instructions:
|
||||
- *regular_test_instructions
|
||||
- !include "{{qt/qtbase}}/cmake_regular_test_instructions.yaml"
|
||||
|
Loading…
Reference in New Issue
Block a user