forked from priv-kweihmann/meta-sca
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
63 lines (63 loc) · 2.34 KB
/
.travis.yml
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
# This is the basic pipeline
language: shell
dist: bionic
sudo: false
addons:
apt:
packages:
# required packages according to bitbake docu
- build-essential
- chrpath
- diffstat
- gawk
- gcc-multilib
- git-core
- libsdl1.2-dev
- python3
- socat
- texinfo
- unzip
- wget
- xterm
env:
global:
- SCA_ENABLE=1
# distro to build
- DISTRO=scatest
# Target branch of other layer-repos
- SCA_BRANCH=master
# bitbake target to build
- SCA_TARGET_IMG=core-image-minimal-scatest
# Builddir
- SCA_BUILDDIR=${TRAVIS_BUILD_DIR}/build
# Max runtime in seconds
- MAXRUNTIME=600
jobs:
include:
- name: "qemux86 classic tools"
env: MACHINE=qemux86 PARAMFILE=standard_01
- name: "qemux86 script tools"
env: MACHINE=qemux86 PARAMFILE=standard_02
- name: "qemux86 system tools"
env: MACHINE=qemux86 PARAMFILE=standard_02
- name: "qemux86 + meta-oe"
env: MACHINE=qemux86 _WITH_METAOE=1 PARAMFILE=metaoe
- name: "qemux86 + clang"
env: MACHINE=qemux86 _WITH_METACLANG=1 PARAMFILE=metaclang
script:
# Clone needed repos
- git clone git://git.yoctoproject.org/poky.git/ -b ${SCA_BRANCH} ${TRAVIS_BUILD_DIR}/poky
- if [ ! -z ${_WITH_METAOE} ]; then git clone git://git.openembedded.org/meta-openembedded -b ${SCA_BRANCH} ${TRAVIS_BUILD_DIR}/meta-oe; fi
- if [ ! -z ${_WITH_METACLANG} ]; then git clone https://github.com/kraj/meta-clang.git -b ${SCA_BRANCH} ${TRAVIS_BUILD_DIR}/meta-clang; fi
# setup poky (is needed to run bitbake-layers afterwards)
- source ${TRAVIS_BUILD_DIR}/poky/oe-init-build-env
# Add meta-sca layer
- bitbake-layers add-layer ${TRAVIS_BUILD_DIR}
- if [ ! -z ${_WITH_METACLANG} ]; then bitbake-layers add-layer ${TRAVIS_BUILD_DIR}/meta-clang; fi
- if [ ! -z ${_WITH_METAOE} ]; then bitbake-layers add-layer ${TRAVIS_BUILD_DIR}/meta-oe/meta-oe; fi
- |
mods=$(cat ${TRAVIS_BUILD_DIR}/test/lang_$PARAMFILE.txt | tr '\n' ' ')
echo "SCA_AVAILABLE_MODULES = \"${mods}\"" >> conf/local.conf
# Run bitbake for 10 minutes to catch any dependency or syntax errors
# on the way, but do not build the whole system, which takes hours not just 10 minutes
- timeout --foreground $MAXRUNTIME bitbake ${SCA_TARGET_IMG} || if [ $? == 124 ]; then echo "Good so far"; else return 1; fi;