blob: 3675ea6e30311cf3ba62ec4dcd7788e89a4ad7ae [file] [log] [blame]
Paul Sokolovskyff61bf22023-08-10 17:10:59 +03001- job:
2 name: tf-m-eclair-daily
Paul Sokolovsky969846c2024-01-11 21:55:20 +03003 node: docker-tf-m-eclair-3.13
Paul Sokolovskyff61bf22023-08-10 17:10:59 +03004 project-type: freestyle
5 concurrent: true
6 disabled: false
7 defaults: global
8 Description: |
9 ECLAIR (MISRA) analysis for Trusted Firmware M
10 properties:
11 - build-discarder:
12 days-to-keep: 60
13 artifact-num-to-keep: 40
Paul Sokolovskyd3902d92023-08-11 19:56:31 +030014 triggers:
Matthew Dalzell69b20c72024-07-11 10:36:42 +010015 - timed: 'H H(2-5) * * 3,7'
Paul Sokolovskyff61bf22023-08-10 17:10:59 +030016 parameters:
17 - string:
18 name: 'FILTER_GROUP'
19 default: "misra"
20 description: |
21 Filter to a group of configurations as recognised by configs.py
22 - string:
23 name: 'CODE_REPO'
24 default: 'https://git.trustedfirmware.org/TF-M/trusted-firmware-m'
25 - string:
26 name: 'CI_SCRIPTS_REPO'
27 default: 'https://git.trustedfirmware.org/ci/tf-m-ci-scripts'
28 - string:
29 name: 'CI_SCRIPTS_BRANCH'
30 default: 'master'
31 - string:
32 name: 'GERRIT_REFSPEC'
Xinyu Zhang8450cc92023-09-21 16:46:13 +080033 default: 'refs/heads/main'
Paul Sokolovskyff61bf22023-08-10 17:10:59 +030034 description: |
Xinyu Zhang8450cc92023-09-21 16:46:13 +080035 For use when triggering with specified tag or master 'refs/heads/main' or 'refs/tags/TF-Mv1.0'.
Paul Sokolovskyff61bf22023-08-10 17:10:59 +030036 - string:
37 name: 'GERRIT_BRANCH'
Xinyu Zhang8450cc92023-09-21 16:46:13 +080038 default: 'main'
Paul Sokolovskyff61bf22023-08-10 17:10:59 +030039 description: |
40 TF-M branch.
41 - string:
42 name: 'GERRIT_HOST'
43 description: |
44 No need to change.
45 - string:
46 name: 'GERRIT_CHANGE_NUMBER'
47 description: |
48 No need to change.
49 - string:
50 name: 'GERRIT_PATCHSET_REVISION'
51 description: |
52 No need to change.
53 - string:
54 name: 'MBEDTLS_VERSION'
Paul Sokolovskyfb7a76b2023-08-17 21:10:45 +030055 default: ''
Paul Sokolovskyff61bf22023-08-10 17:10:59 +030056 description: |
57 Specify which MBEDTLS version to use
58 refs/heads/<branch_name> : Pick up latest HEAD on branch
59 TAG_NAME : Pick up a tagged version
60 full commit hash : Pick up a specific commit
61 - string:
62 name: 'MBEDTLS_URL'
63 default: 'https://git.trustedfirmware.org/mirror/mbed-tls.git'
64 - string:
65 name: 'QCBOR_URL'
66 default: 'https://github.com/laurencelundblade/QCBOR.git'
67 - string:
68 name: 'QCBOR_VERSION'
Paul Sokolovsky027c3102023-08-18 13:38:27 +030069 default: ''
Paul Sokolovskyff61bf22023-08-10 17:10:59 +030070 description: |
71 Specify which QCBOR version to use
72 refs/heads/<branch_name> : Pick up latest HEAD on branch
73 TAG_NAME : Pick up a tagged version
74 full commit hash : Pick up a specific commit
75 - string:
Matthew Dalzell21057ce2025-02-28 17:20:19 +000076 name: 'T_COSE_URL'
77 default: 'https://github.com/laurencelundblade/t_cose.git'
78 - string:
79 name: 'T_COSE_VERSION'
80 default: ''
81 description: |
82 Specify which t_cose version to use
83 refs/heads/<branch_name> : Pick up latest HEAD on branch
84 TAG_NAME : Pick up a tagged version
85 full commit hash : Pick up a specific commit
86 - string:
Paul Sokolovskyff61bf22023-08-10 17:10:59 +030087 name: 'MCUBOOT_REFSPEC'
Paul Sokolovsky027c3102023-08-18 13:38:27 +030088 default: ''
Paul Sokolovskyff61bf22023-08-10 17:10:59 +030089 description: |
90 Specify which MCUboot version to use
91 refs/heads/<branch_name> : Pick up latest HEAD on branch
92 TAG_NAME : Pick up a tagged version
93 full commit hash : Pick up a specific commit
94 - string:
95 name: 'MCUBOOT_URL'
96 default: 'https://git.trustedfirmware.org/mirror/mcuboot.git'
97 - string:
98 name: 'TFM_TESTS_URL'
99 default: 'https://git.trustedfirmware.org/TF-M/tf-m-tests.git'
100 - string:
101 name: 'TFM_TESTS_REFSPEC'
Paul Sokolovsky027c3102023-08-18 13:38:27 +0300102 default: ''
Paul Sokolovskyff61bf22023-08-10 17:10:59 +0300103 - string:
Matthew Dalzelldca58c72025-05-16 17:39:01 +0100104 name: 'TFM_EXTRAS_URL'
105 default: 'https://git.trustedfirmware.org/TF-M/tf-m-extras.git'
106 - string:
107 name: 'TFM_EXTRAS_REFSPEC'
108 default: ''
109 description: |
110 Specify which tf-m-extras version to use
111 refs/heads/<branch_name> : Pick up latest HEAD on branch
112 TAG_NAME : Pick up a tagged version
113 full commit hash : Pick up a specific commit
114 - string:
Paul Sokolovskyff61bf22023-08-10 17:10:59 +0300115 name: 'PSA_ARCH_TESTS_URL'
116 default: 'https://git.trustedfirmware.org/mirror/psa-arch-tests.git'
117 - string:
118 name: 'PSA_ARCH_TESTS_VERSION'
Paul Sokolovsky027c3102023-08-18 13:38:27 +0300119 default: ''
Paul Sokolovskyff61bf22023-08-10 17:10:59 +0300120 - string:
121 name: SHARE_FOLDER
Paul Sokolovsky44971fa2023-08-11 14:15:56 +0300122 default: '/tmp'
123 description: 'Folder for initial cloning of repositories'
Paul Sokolovskyff61bf22023-08-10 17:10:59 +0300124 - string:
125 name: 'BUILD_TARGET'
126 default: ''
127 description: |
128 Override build target (for debugging)
129 - string:
130 name: 'BUILD_JOBS'
131 default: '16'
132 description: |
133 --jobs to pass to make, etc.
134 wrappers:
135 - timestamps
136 - timeout:
137 timeout: 2400
138 fail: true
139 builders:
140 - shell: |
141 #!/bin/bash -ex
142 git clone -b $CI_SCRIPTS_BRANCH $CI_SCRIPTS_REPO tf-m-ci-scripts
143 git clone -b master https://git.trustedfirmware.org/ci/tf-ci-scripts.git tf-ci-scripts
144 tf-m-ci-scripts/clone.sh
145
146 export ECLAIR_CONFIG_DIR=$PWD/tf-m-ci-scripts/eclair
147 . tf-ci-scripts/eclair/utils.sh
148 . tf-m-ci-scripts/eclair/utils_tfm.sh
149
150 export CROSS_COMPILE="arm-none-eabi-"
151 export CC_ALIASES="${CROSS_COMPILE}gcc"
152 export CXX_ALIASES="${CROSS_COMPILE}g++"
153 export LD_ALIASES="${CROSS_COMPILE}ld"
154 export AR_ALIASES="${CROSS_COMPILE}ar"
155 export AS_ALIASES="${CROSS_COMPILE}as"
156 export FILEMANIP_ALIASES="cp mv ${CROSS_COMPILE}objcopy"
157
158 # Detach license for initial eclair_env invocation. We then extend it on
159 # each config build iteration.
160 detachLicense 600
161
162 # Toolchain path must be already set before calling eclair_env, can't set it inside it.
163 # And to set toolchain path, we need a CONFIG_NAME
164 CONFIG_NAME=$(python3 tf-m-ci-scripts/configs.py -g $FILTER_GROUP | head -1)
165 eclair_tfm_set_toolchain_path
166
167 export ECLAIR_ANALYSIS=ECLAIR
168 eclair_prepare
169 eclair_analyze tf-m-ci-scripts/run-eclair-builds.sh
170 eclair_make_ecd
171 eclair_make_reports
172 tf-ci-scripts/eclair/analyze_index_html.sh
173
174 publishers:
175 - archive:
176 artifacts: ECLAIR/**, index.html
177 latest-only: false
178 allow-empty: true
Paul Sokolovsky40dfb482023-08-11 19:47:25 +0300179 - email:
180 recipients: 'paul.sokolovsky@linaro.org'