aboutsummaryrefslogtreecommitdiff
path: root/tcwg-buildfarm-test-builder.yaml
blob: 1a5baa6bd3fa8999d856c50f804d887429b14feb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
- job:
    name: tcwg-buildfarm-test-builder
    project-type: matrix
    defaults: global
    logrotate:
        daysToKeep: 30
        numToKeep: 30
    properties:
        - authorization:
            anonymous:
                - job-read
                - job-extended-read
            linaro:
                - job-build
                - job-cancel
    parameters:
        - string:
            name: gcc_branch
            default: 'latest'
            description: 'GCC revision to build'
        - string:
            name: languages
            default: 'default'
            description: 'Languages to build, e.g., "c,c++" or "all" or "default"'
        - bool:
            name: try_bootstrap
            default: 'true'
            description: 'Attempt to bootstrap GCC for compatible host and target combinations'
        - string:
            name: excludecheck
            default: 'gdb'
            description: 'Do not run "make check" on this component'
    disabled: false
    node: tcwg-x86_64
    concurrent: true
    display-name: 'TCWG BuildFarm on tcwg-test builders'
    scm:
        - git:
            url: https://git.linaro.org/toolchain/abe.git
            refspec: ${GERRIT_REFSPEC}
            name: ''
            branches:
                - ${GERRIT_PATCHSET_REVISION}
            skip-tag: true
            shallow-clone: true
            wipe-workspace: true
            choosing-strategy: gerrit
    triggers:
        - gerrit:
            server-name: 'review.linaro.org'
            override-votes: true
            gerrit-build-successful-verified-value: 1
            gerrit-build-failed-verified-value: -1
            gerrit-build-successful-codereview-value: 1
            gerrit-build-failed-codereview-value: -1
            readable-message: true
            successful-message: 'Sanity check OK'
            failure-message: '[OUTPUT]:'
            trigger-for-unreviewed-patches: true
            projects:
                - project-compare-type: 'ANT'
                  project-pattern: 'toolchain/abe'
                  branches:
                    - branch-compare-type: 'ANT'
                      branch-pattern: 'master'
    axes:
        - axis:
            type: slave
            name: label
            values:
                - tcwg-test
        - axis:
            type: user-defined
            name: target
            values:
                - aarch64-linux-gnu
                - aarch64-none-elf
                - aarch64_be-none-elf
                - arm-linux-gnueabi
                - arm-linux-gnueabihf
                - armeb-linux-gnueabihf
                - native
                - schroot-i386-native
    execution-strategy:
        sequential: false
    wrappers:
        - timeout:
            timeout: 300
        - timestamps
        - ssh-agent-credentials:
            # tcwg-buildslave user id
            user: 'e0958a95-204f-4c14-a66c-5e2be6c5d50a'
        - build-name:
            name: '#${BUILD_NUMBER}-${ENV,var="gcc_branch"}'
        - matrix-tie-parent:
            node: tcwg-x86_64-01
    builders:
        - shell: |
            #!/bin/bash

            set -e
            set -x

            case ${target} in
              schroot-*)
                schroot_arch=$(echo ${target} | sed -e "s/^schroot-\([^-]*\)-\(.*\)/\1/")
                target=$(echo ${target} | sed -e "s/^schroot-\([^-]*\)-\(.*\)/\2/")
                BUILD_SHELL="schroot -c tcwg-build-${schroot_arch}-trusty --preserve-environment -- bash"
                ;;
              *)
                BUILD_SHELL="bash"
                ;;
            esac

            ${BUILD_SHELL} -x ./jenkins.sh --target ${target} --gcc-branch ${gcc_branch} --languages ${languages} ${try_bootstrap:+ --bootstrap} --runtests ${excludecheck:+ --excludecheck ${excludecheck}}
    publishers:
        - email-ext:
            recipients: 'christophe.lyon@linaro.org'
            attach-build-log: false
            matrix-trigger: both
            always: true