diff options
author | Samuli Piippo <samuli.piippo@qt.io> | 2023-05-25 13:41:56 +0300 |
---|---|---|
committer | Samuli Piippo <samuli.piippo@qt.io> | 2023-06-05 16:59:49 +0300 |
commit | 64029b6c561168037727c2d37cb87b53fb35355b (patch) | |
tree | 72e3453d9de98c1c56cffc9fdd4bcaa207196931 | |
parent | 6c76252e6f6bf61ab815b9fbd710da93ef6f9b46 (diff) |
Add CI support
Build common targets against different Qt versions.
Task-number: QTBUG-108502
Change-Id: I5965a5be7e5ca50cbfa22ac31d1fac747368869f
Reviewed-by: Mikko Gronoff <mikko.gronoff@qt.io>
-rw-r--r-- | coin/dependencies.yaml | 5 | ||||
-rw-r--r-- | coin/module_config.yaml | 112 |
2 files changed, 117 insertions, 0 deletions
diff --git a/coin/dependencies.yaml b/coin/dependencies.yaml new file mode 100644 index 0000000..e708d8e --- /dev/null +++ b/coin/dependencies.yaml @@ -0,0 +1,5 @@ +product_dependency: + ../../qt/qt5: + ref: "dev" +dependencies: + {} diff --git a/coin/module_config.yaml b/coin/module_config.yaml new file mode 100644 index 0000000..b72f79e --- /dev/null +++ b/coin/module_config.yaml @@ -0,0 +1,112 @@ +version: 2 +tags: ["git"] +accept_configuration: + condition: and + conditions: + - condition: property + property: host.compiler + equals_value: Yocto + - condition: property + property: target.arch + in_values: [TARGET1, TARGET2, TARGET3] + +machine_type: + Build: + cores: 16 + +target1: &target1 + type: Group + instructions: + - type: EnvironmentVariable + variableName: MACHINE + variableValue: salvator-x + - type: EnvironmentVariable + variableName: MANIFEST + variableValue: renesas/dev.xml + enable_if: + condition: property + property: target.arch + equals_value: TARGET1 +target2: &target2 + type: Group + instructions: + - type: EnvironmentVariable + variableName: MACHINE + variableValue: h3ulcb + - type: EnvironmentVariable + variableName: MANIFEST + variableValue: renesas/6.5.xml + enable_if: + condition: property + property: target.arch + equals_value: TARGET2 +target3: &target3 + type: Group + instructions: + - type: EnvironmentVariable + variableName: MACHINE + variableValue: m3ulcb + - type: EnvironmentVariable + variableName: MANIFEST + variableValue: renesas/lts-6.2.xml + enable_if: + condition: property + property: target.arch + equals_value: TARGET3 + +instructions: + Build: + - *target1 + - *target2 + - *target3 + - type: EnvironmentVariable + variableName: SOURCE_DIR + variableValue: "{{.SourceDir}}" + - type: SetBuildDirectory + directory: "{{.AgentWorkingDir}}/build" + - type: MakeDirectory + directory: "{{.BuildDir}}" + - type: ChangeDirectory + directory: "{{.BuildDir}}" + - type: WriteFile + fileContents: | + #!/bin/bash -xe + + # make hostname unique for NFS + sudo hostname $(hostname -s)-$(date +%s%N) + + sudo mkdir -p /mnt/yocto-cache + sudo mount yocto-cache.ci.qt.io:/srv/yocto-cache /mnt/yocto-cache + + curl https://storage.googleapis.com/git-repo-downloads/repo > repo + chmod +x repo + + ./repo init \ + --repo-url https://github.com/theqtcompany/git-repo \ + -u git://code.qt.io/yocto/boot2qt-manifest \ + -m ${MANIFEST} \ + --reference /mnt/yocto-cache/mirror \ + --group all + ./repo sync + (cd sources/renesas-rcar3; git lfs pull) + + rm -rf sources/meta-boot2qt-renesas + ln -s ${SOURCE_DIR} sources/meta-boot2qt-renesas + + source ./setup-environment.sh build + echo "require ../sources/meta-qt6/coin/test-ci.inc" >> conf/local.conf + + bitbake meta-b2qt-embedded-qbsp + SDKMACHINE=x86_64-mingw32 bitbake meta-b2qt-embedded-qbsp + filename: "{{.BuildDir}}/start-build" + fileMode: 420 + - type: ExecuteCommand + command: ["bash", "-xe", "{{.BuildDir}}/start-build"] + maxTimeInSeconds: 43200 + maxTimeBetweenOutput: 7200 + userMessageOnFailure: "Build failed." + - type: ExecuteCommand + command: ["sudo", "umount", "/mnt/yocto-cache"] + userMessageOnFailure: "Unmounting cache failed." + + Test: [] |