summaryrefslogtreecommitdiffstats
path: root/coin
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2019-10-11 15:13:48 +0200
committerLiang Qi <liang.qi@qt.io>2019-10-11 20:51:17 +0000
commitf03ac58b1ecc24f01cb83b275a9b6088f9483545 (patch)
treebff33cde084ab584d734871d0af34ab1c369297d /coin
parent9bd6cec74dbbc5aece55dc0c8808494db29b9963 (diff)
cmake: add Android build
Task-number: QTBUG-78945 Change-Id: I0c9d3cc7de6d3bfb346a77d95a6bbcad6d707a74 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Qt CMake Build Bot
Diffstat (limited to 'coin')
-rw-r--r--coin/instructions/cmake_cross_compilation.yaml58
-rw-r--r--coin/module_config.yaml45
2 files changed, 94 insertions, 9 deletions
diff --git a/coin/instructions/cmake_cross_compilation.yaml b/coin/instructions/cmake_cross_compilation.yaml
new file mode 100644
index 0000000000..2037a4d331
--- /dev/null
+++ b/coin/instructions/cmake_cross_compilation.yaml
@@ -0,0 +1,58 @@
+type: Group
+instructions:
+ - type: MakeDirectory
+ directory: .git
+ - type: MakeDirectory
+ directory: build
+ - type: ChangeDirectory
+ directory: "{{.BuildDir}}/build"
+ - type: MakeDirectory
+ directory: host
+ - type: MakeDirectory
+ directory: target
+ - type: SetBuildDirectory
+ directory: "{{.SourceDir}}/build/host"
+ - type: ChangeDirectory
+ directory: "{{.BuildDir}}"
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake {{.Env.CONFIGURE_ARGS}} -DCMAKE_INSTALL_PREFIX:PATH={{.InstallDir}}/host -DBUILD_TESTING=OFF {{.SourceDir}}"
+ executeCommandArgumentSplitingBehavior: SplitAfterVariableSubstitution
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to call cmake. Contact Liang then.
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake --build . --parallel"
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ 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: 1200
+ userMessageOnFailure: >
+ Failed to install package.
+ - type: SetBuildDirectory
+ directory: "{{.SourceDir}}/build/target"
+ - type: ChangeDirectory
+ directory: "{{.BuildDir}}"
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake {{.Env.TARGET_CONFIGURE_ARGS}} -DQT_HOST_PATH={{.InstallDir}}/host -DCMAKE_INSTALL_PREFIX:PATH={{.InstallDir}}/target -DBUILD_TESTING=OFF {{.SourceDir}}"
+ executeCommandArgumentSplitingBehavior: SplitAfterVariableSubstitution
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to call cmake. Contact Liang then.
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake --build . --parallel"
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ 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: 1200
+ userMessageOnFailure: >
+ Failed to install package.
diff --git a/coin/module_config.yaml b/coin/module_config.yaml
index 75607753cc..8db848012c 100644
--- a/coin/module_config.yaml
+++ b/coin/module_config.yaml
@@ -1,13 +1,40 @@
-version: 1
+version: 2
accept_configuration:
condition: property
- property: host.os
- equals_property: target.os
+ property: features
+ not_contains_value: Disable
-build_instructions:
- - !include "{{qt/qtbase}}/prepare_building_env.yaml"
- - !include "{{qt/qtbase}}/cmake_qtbase_build_instructions.yaml"
- - !include "{{qt/qtbase}}/cmake_build_and_upload_test_artifacts.yaml"
+instructions:
+ Build:
+ - !include "{{qt/qtbase}}/prepare_building_env.yaml"
+ - type: Group
+ instructions:
+ - !include "{{qt/qtbase}}/cmake_qtbase_build_instructions.yaml"
+ - !include "{{qt/qtbase}}/cmake_build_and_upload_test_artifacts.yaml"
+ enable_if:
+ condition: property
+ property: host.os
+ equals_property: target.os
+ - type: Group
+ instructions:
+ - !include "{{qt/qtbase}}/cmake_cross_compilation.yaml"
+ disable_if:
+ condition: property
+ property: host.os
+ equals_property: target.os
-test_instructions:
- - !include "{{qt/qtbase}}/cmake_regular_test_instructions.yaml"
+ Test:
+ - type: Group
+ instructions:
+ - !include "{{qt/qtbase}}/cmake_regular_test_instructions.yaml"
+ enable_if:
+ condition: property
+ property: host.os
+ equals_value: target.os
+ - type: EnvironmentVariable
+ variableName: Dummy
+ variableValue: dummy
+ disable_if:
+ condition: property
+ property: host.os
+ equals_property: target.os