-
Notifications
You must be signed in to change notification settings - Fork 0
/
test-criu-32cr.sh
executable file
·57 lines (45 loc) · 1.27 KB
/
test-criu-32cr.sh
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
#!/bin/bash
echo "======================================"
echo "=== Start CRIU tests on linux-next ==="
echo "======================================"
PKGS="libcap-dev:i386 libaio1:i386 libaio-dev:i386 libnl-3-dev:i386 \
libnl-route-3-dev:i386"
NR_CPU=$(grep -c ^processor /proc/cpuinfo)
FAILED=0
HOME="$(pwd)"
function dropbox_dump_upload()
{
if [[ $FAILED -eq 1 ]] ; then
find ./test/dump -type f | while read f ; do
${HOME}/dropbox_upload.py "$f" "$(dirname $f)"
done
fi
}
set -x -e
# Building criu-dev's CRIU binary
cd criu
make mrproper
git fetch origin
git checkout criu-dev
git clean -fdx
make -j$((NR_CPU+1))
ccache -s
# Installing 32-bit libraries, it needs to be done after
# building CRIU as *-dev versions in ubuntu conflicts
# for :x86_64 and for :i386.
dpkg --add-architecture i386
apt-get update -qq
apt-get install -qq ${PKGS}
make -j$((NR_CPU+1)) COMPAT_TEST=y -C test/zdtm
ccache -s
umask 0000
chmod 0777 test/
chmod 0777 test/zdtm/static
chmod 0777 test/zdtm/transition
./criu/criu check --extra --all || echo $?
./criu/criu check --feature compat_cr
./test/zdtm.py run -a -p 4 -x zdtm/static/autofs --keep-going || FAILED=1
echo 'function prep() { :; }' > ./test/jenkins/criu-lib.sh
bash ./test/jenkins/criu-fault.sh || FAILED=1
dropbox_dump_upload
exit $FAILED