| 1 | --- |
| 2 | - defaults: |
| 3 | name: lttng-modules |
| 4 | description: | |
| 5 | The LTTng modules provide Linux kernel tracing capability to the LTTng |
| 6 | 2.0 tracer toolset. |
| 7 | |
| 8 | <p>Job is managed by Jenkins Job Builder.</p> |
| 9 | |
| 10 | project-type: freestyle |
| 11 | |
| 12 | wrappers: |
| 13 | - workspace-cleanup |
| 14 | - timestamps |
| 15 | - ansicolor |
| 16 | |
| 17 | scm: |
| 18 | - git: |
| 19 | url: git://github.com/{github_user}/{github_name}.git |
| 20 | browser: githubweb |
| 21 | browser-url: https://github.com/{github_user}/{github_name} |
| 22 | branches: |
| 23 | - "{mversion}" |
| 24 | shallow-clone: true |
| 25 | skip-tag: true |
| 26 | fastpoll: true |
| 27 | basedir: src/lttng-modules |
| 28 | |
| 29 | triggers: |
| 30 | - pollscm: |
| 31 | cron: "@hourly" |
| 32 | |
| 33 | properties: |
| 34 | - build-discarder: |
| 35 | num-to-keep: 2 |
| 36 | - github: |
| 37 | url: https://github.com/{github_user}/{github_name} |
| 38 | |
| 39 | |
| 40 | ## Templates |
| 41 | - job-template: |
| 42 | name: lttng-modules_{mversion}_{kversion}_{buildtype} |
| 43 | defaults: lttng-modules |
| 44 | |
| 45 | project-type: matrix |
| 46 | node: 'master' # Applies only to matrix flyweight task |
| 47 | axes: |
| 48 | - axis: |
| 49 | type: slave |
| 50 | name: arch |
| 51 | values: '{obj:arch}' |
| 52 | |
| 53 | builders: |
| 54 | - copyartifact: |
| 55 | project: kernel_{kversion}_{buildtype}/arch=$arch |
| 56 | which-build: last-successful |
| 57 | stable: true |
| 58 | filter: 'build/**' |
| 59 | target: 'deps/linux' |
| 60 | do-not-fingerprint: true |
| 61 | - shell: | |
| 62 | git clone --depth=1 -b "v{kversion}" --reference $HOME/gitcache/linux-stable.git/ git://git-mirror.internal.efficios.com/kernel/stable/linux-stable.git src/linux |
| 63 | - shell: |
| 64 | !include-raw-escape: scripts/lttng-modules/build.sh |
| 65 | |
| 66 | publishers: |
| 67 | - archive: |
| 68 | artifacts: 'build/**' |
| 69 | allow-empty: false |
| 70 | - workspace-cleanup |
| 71 | |
| 72 | - job-template: |
| 73 | name: lttng-modules_{mversion}_build-vanilla |
| 74 | defaults: lttng-modules |
| 75 | description: | |
| 76 | The LTTng modules provide Linux kernel tracing capability to the LTTng |
| 77 | 2.0 tracer toolset. |
| 78 | |
| 79 | This job will build the {mversion} branch against all stable vanilla |
| 80 | kernel tags. |
| 81 | |
| 82 | <p>Job is managed by Jenkins Job Builder.</p> |
| 83 | |
| 84 | node: 'master' |
| 85 | |
| 86 | parameters: |
| 87 | - string: |
| 88 | name: 'mversion' |
| 89 | default: '{mversion}' |
| 90 | description: 'The lttng-modules branch to build.' |
| 91 | - string: |
| 92 | name: 'maxConcurrentBuild' |
| 93 | default: '20' |
| 94 | description: 'The maximum number of concurrent child build to run.' |
| 95 | - string: |
| 96 | name: 'kverfloor' |
| 97 | default: 'v2.6.36' |
| 98 | description: 'The lowest kernel version to build.' |
| 99 | - string: |
| 100 | name: 'kgitrepo' |
| 101 | default: 'git://git-mirror.internal.efficios.com/kernel/stable/linux-stable.git' |
| 102 | description: 'The linux kernel git repository url.' |
| 103 | - string: |
| 104 | name: 'kbuildjob' |
| 105 | default: 'lttng-modules_VERSION_param-build' |
| 106 | description: 'The parametrized job to use for child builds.' |
| 107 | |
| 108 | builders: |
| 109 | - system-groovy: |
| 110 | command: |
| 111 | !include-raw-escape: scripts/lttng-modules/master-vanilla.groovy |
| 112 | |
| 113 | publishers: |
| 114 | - workspace-cleanup |
| 115 | |
| 116 | - job-template: |
| 117 | name: lttng-modules_{mversion}_build-{uversion} |
| 118 | defaults: lttng-modules |
| 119 | description: | |
| 120 | The LTTng modules provide Linux kernel tracing capability to the LTTng |
| 121 | 2.0 tracer toolset. |
| 122 | |
| 123 | This job will build the {mversion} branch against all Ubuntu {uversion} |
| 124 | released kernels, including the LTS backport kernels. |
| 125 | |
| 126 | <p>Job is managed by Jenkins Job Builder.</p> |
| 127 | |
| 128 | node: 'master' |
| 129 | |
| 130 | parameters: |
| 131 | - string: |
| 132 | name: 'mversion' |
| 133 | default: '{mversion}' |
| 134 | description: 'The lttng-modules branch to build.' |
| 135 | - string: |
| 136 | name: 'maxConcurrentBuild' |
| 137 | default: '20' |
| 138 | description: 'The maximum number of concurrent child build to run.' |
| 139 | - string: |
| 140 | name: 'uversion' |
| 141 | default: '{uversion}' |
| 142 | description: 'The lowest kernel version to build.' |
| 143 | - string: |
| 144 | name: 'kgitrepo' |
| 145 | default: 'git://git-mirror.internal.efficios.com/git/ubuntu-{uversion}.git' |
| 146 | description: 'The linux kernel git repository url.' |
| 147 | - string: |
| 148 | name: 'kbuildjob' |
| 149 | default: 'lttng-modules_VERSION_param-build' |
| 150 | description: 'The parametrized job to use for child builds.' |
| 151 | |
| 152 | builders: |
| 153 | - system-groovy: |
| 154 | command: |
| 155 | !include-raw-escape: scripts/lttng-modules/master-ubuntu.groovy |
| 156 | |
| 157 | publishers: |
| 158 | - workspace-cleanup |
| 159 | |
| 160 | - job-template: |
| 161 | name: lttng-modules_{mversion}_build-rt |
| 162 | defaults: lttng-modules |
| 163 | description: | |
| 164 | The LTTng modules provide Linux kernel tracing capability to the LTTng |
| 165 | 2.0 tracer toolset. |
| 166 | |
| 167 | This job will build the {mversion} branch against all Linutronix RT |
| 168 | kernels. |
| 169 | |
| 170 | <p>Job is managed by Jenkins Job Builder.</p> |
| 171 | |
| 172 | node: 'master' |
| 173 | |
| 174 | parameters: |
| 175 | - string: |
| 176 | name: 'mversion' |
| 177 | default: '{mversion}' |
| 178 | description: 'The lttng-modules branch to build.' |
| 179 | - string: |
| 180 | name: 'maxConcurrentBuild' |
| 181 | default: '20' |
| 182 | description: 'The maximum number of concurrent child build to run.' |
| 183 | - string: |
| 184 | name: 'kverfloor' |
| 185 | default: 'v2.6.36-rt0-rebase' |
| 186 | description: 'The lowest kernel version to build.' |
| 187 | - string: |
| 188 | name: 'kgitrepo' |
| 189 | default: 'git://git-mirror.internal.efficios.com/kernel/rt/linux-rt-devel.git' |
| 190 | description: 'The linux kernel git repository url.' |
| 191 | - string: |
| 192 | name: 'kbuildjob' |
| 193 | default: 'lttng-modules_VERSION_param-build' |
| 194 | description: 'The parametrized job to use for child builds.' |
| 195 | |
| 196 | builders: |
| 197 | - system-groovy: |
| 198 | command: |
| 199 | !include-raw-escape: scripts/lttng-modules/master-rt.groovy |
| 200 | |
| 201 | publishers: |
| 202 | - workspace-cleanup |
| 203 | |
| 204 | - job-template: |
| 205 | name: lttng-modules_VERSION_param-build |
| 206 | defaults: lttng-modules |
| 207 | description: | |
| 208 | This is a parametrized job used by 'master' jobs to build any combinations |
| 209 | of lttng-modules and linux kernel versions. |
| 210 | |
| 211 | <p>Job is managed by Jenkins Job Builder.</p> |
| 212 | |
| 213 | project-type: matrix |
| 214 | node: 'master' # Applies only to matrix flyweight task |
| 215 | axes: |
| 216 | - axis: |
| 217 | type: slave |
| 218 | name: arch |
| 219 | values: '{obj:arch}' |
| 220 | |
| 221 | properties: |
| 222 | - build-discarder: |
| 223 | days-to-keep: 2 |
| 224 | |
| 225 | parameters: |
| 226 | - string: |
| 227 | name: 'mversion' |
| 228 | default: 'master' |
| 229 | description: 'The lttng-modules branch to build.' |
| 230 | - string: |
| 231 | name: 'kversion' |
| 232 | default: '' |
| 233 | description: 'The linux kernel git tag to build against.' |
| 234 | - string: |
| 235 | name: 'kgitrepo' |
| 236 | default: 'git://git-mirror.internal.efficios.com/kernel/stable/linux-stable.git' |
| 237 | description: 'The linux kernel git repository url.' |
| 238 | |
| 239 | concurrent: true |
| 240 | |
| 241 | scm: |
| 242 | - git: |
| 243 | url: git://github.com/lttng/lttng-modules.git |
| 244 | browser: githubweb |
| 245 | browser-url: https://github.com/lttng/lttng-modules |
| 246 | branches: |
| 247 | - "${{mversion}}" |
| 248 | skip-tag: true |
| 249 | basedir: src/lttng-modules |
| 250 | |
| 251 | triggers: |
| 252 | |
| 253 | builders: |
| 254 | - shell: | |
| 255 | git clone --depth=1 -b "$kversion" --reference $HOME/gitcache/linux-stable.git/ "$kgitrepo" src/linux |
| 256 | - shell: |
| 257 | !include-raw-escape: scripts/lttng-modules/param-build.sh |
| 258 | |
| 259 | publishers: |
| 260 | - workspace-cleanup |
| 261 | |
| 262 | - job-template: |
| 263 | name: lttng-modules_{mversion}_coverity |
| 264 | defaults: lttng-modules |
| 265 | node: 'x86-64' |
| 266 | |
| 267 | triggers: |
| 268 | - pollscm: |
| 269 | cron: "@daily" |
| 270 | |
| 271 | wrappers: |
| 272 | - workspace-cleanup |
| 273 | - timestamps |
| 274 | - ansicolor: |
| 275 | colormap: xterm |
| 276 | - credentials-binding: |
| 277 | - username-password-separated: |
| 278 | credential-id: lttng-modules_coverity_token |
| 279 | username: COVERITY_SCAN_PROJECT_NAME |
| 280 | password: COVERITY_SCAN_TOKEN |
| 281 | |
| 282 | builders: |
| 283 | - shell: | |
| 284 | git clone --depth=1 -b v4.4 --reference $HOME/gitcache/linux-stable.git/ git://git-mirror.internal.efficios.com/kernel/stable/linux-stable.git src/linux |
| 285 | cd src/linux |
| 286 | make defconfig |
| 287 | sed -i "s/# CONFIG_KALLSYMS_ALL is not set/CONFIG_KALLSYMS_ALL=y/g" .config |
| 288 | make modules_prepare |
| 289 | - shell: |
| 290 | !include-raw-escape: scripts/common/coverity.sh |
| 291 | |
| 292 | publishers: |
| 293 | - workspace-cleanup |
| 294 | |
| 295 | - job-template: |
| 296 | name: lttng-modules_{mversion}_cppcheck |
| 297 | defaults: lttng-modules |
| 298 | |
| 299 | triggers: |
| 300 | - pollscm: |
| 301 | cron: "@daily" |
| 302 | |
| 303 | builders: |
| 304 | - shell: | |
| 305 | rm -f cppcheck.xml |
| 306 | cppcheck --enable=all --xml --xml-version=2 $WORKSPACE/src/lttng-modules 2> cppcheck.xml |
| 307 | |
| 308 | publishers: |
| 309 | - archive: |
| 310 | artifacts: 'cppcheck.xml' |
| 311 | allow-empty: false |
| 312 | - cppcheck: |
| 313 | pattern: 'cppcheck.xml' |
| 314 | - email: |
| 315 | recipients: 'ci-notification@lists.lttng.org' |
| 316 | notify-every-unstable-build: true |
| 317 | send-to-individuals: false |
| 318 | |
| 319 | - job-template: |
| 320 | name: lttng-modules_{mversion}_sloccount |
| 321 | defaults: lttng-modules |
| 322 | description: | |
| 323 | The LTTng modules provide Linux kernel tracing capability to the LTTng |
| 324 | 2.0 tracer toolset. |
| 325 | |
| 326 | This job runs the sloccount utility and generates a trend report. |
| 327 | |
| 328 | <p>Job is managed by Jenkins Job Builder.</p> |
| 329 | |
| 330 | triggers: |
| 331 | - pollscm: |
| 332 | cron: "@daily" |
| 333 | |
| 334 | builders: |
| 335 | - shell: | |
| 336 | cloc --by-file --xml --out=cloc.xml src/lttng-modules/ |
| 337 | |
| 338 | publishers: |
| 339 | - archive: |
| 340 | artifacts: 'cloc.xml' |
| 341 | allow-empty: false |
| 342 | - sloccount: |
| 343 | report-files: 'cloc.xml' |
| 344 | |
| 345 | |
| 346 | ## Project |
| 347 | - project: |
| 348 | name: lttng-modules |
| 349 | github_user: lttng |
| 350 | github_name: lttng-modules |
| 351 | mversion: |
| 352 | - stable-2.7 |
| 353 | - stable-2.8 |
| 354 | - master |
| 355 | jobs: |
| 356 | - 'lttng-modules_{mversion}_build-vanilla' |
| 357 | - 'lttng-modules_{mversion}_build-rt': |
| 358 | mversion: master |
| 359 | - 'lttng-modules_{mversion}_build-{uversion}': |
| 360 | uversion: |
| 361 | - trusty |
| 362 | - xenial |
| 363 | - 'lttng-modules_VERSION_param-build': |
| 364 | arch: !!python/tuple [x86-32, x86-64] |
| 365 | - 'lttng-modules_{mversion}_cppcheck' |
| 366 | - 'lttng-modules_{mversion}_sloccount': |
| 367 | mversion: master |
| 368 | - 'lttng-modules_{mversion}_coverity': |
| 369 | mversion: master |