blob: 056178b5728f3df33cc86fdc1da0ceb492fe0025 (
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
|
- job:
name: u-boot-upstream
project-type: freestyle
defaults: global
logrotate:
daysToKeep: 30
numToKeep: 30
properties:
- authorization:
anonymous:
- job-read
- job-extended-read
linaro:
- job-read
- job-extended-read
- job-build
- job-cancel
disabled: false
node: docker-utopic-amd64
display-name: 'U-Boot upstream (mainline)'
scm:
- git:
url: git://git.denx.de/u-boot.git
refspec: +refs/heads/master:refs/remotes/origin/master
name: origin
branches:
- refs/heads/master
skip-tag: true
shallow-clone: true
wipe-workspace: false
wrappers:
- timestamps
- build-name:
name: '#${BUILD_NUMBER}-${GIT_REVISION,length=8}'
builders:
- linaro-publish-token
- shell: |
#!/bin/bash
set -ex
trap cleanup_exit INT TERM EXIT
cleanup_exit()
{
cd ${WORKSPACE}
rm -rf build out
git clean -fdx
}
sudo sed -i -e 's/archive.ubuntu.com\|security.ubuntu.com/old-releases.ubuntu.com/g' /etc/apt/sources.list
sudo apt-get update
sudo apt-get install -y libssl-dev python-pycurl rsync
# Use pre-installed linaro toolchain
export PATH="${HOME}/srv/toolchain/arm-tc-15.02/bin:${HOME}/srv/toolchain/arm64-tc-15.02/bin:$PATH"
export CROSS_COMPILE="arm-linux-gnueabihf-"
# Hack to avoid to clean the build as we want to publish build artifacts
sed -i "s|\t\t\${MAKE} -s clean||" MAKEALL
# FIXME kill_children doesn't kill only the children, it kills also the shell parents
# java -jar slave.jar -> /bin/bash /tmp/hudsonXXX.sh -> MAKEALL
sed -i "s|\t\tkill_children|\t\tkill -- -\$$|" MAKEALL
for CPU in armv7 armv8; do
[ "${CPU}" = "armv8" ] && export CROSS_COMPILE="aarch64-linux-gnu-"
export BUILD_DIR="${WORKSPACE}/build/${CPU}"
export BUILD_NBUILDS=2
./MAKEALL --cpu ${CPU}
done
# Publish
find build -type f -name '.config' -exec rename 's/.config/u-boot.config/' {} +
rsync -avm \
--include=u-boot \
--include=u-boot-spl \
--include=u-boot.config \
--include='*/' \
--exclude='*' \
build/ out/
test -d ${HOME}/bin || mkdir ${HOME}/bin
wget -q https://git.linaro.org/ci/publishing-api.git/blob_plain/HEAD:/linaro-cp.py -O ${HOME}/bin/linaro-cp.py
time python ${HOME}/bin/linaro-cp.py \
--link-latest \
out components/kernel/u-boot/${BUILD_NUMBER}
publishers:
- email:
recipients: 'andrey.konovalov@linaro.org fathi.boudra@linaro.org'
|