2016-12-02 14:46:02 +00:00
|
|
|
# Workaround for the issue found in the stable image promoted on Dec 1, 2016.
|
|
|
|
# See https://github.com/travis-ci/travis-ci/issues/6928#issuecomment-264227708
|
|
|
|
group: deprecated
|
|
|
|
|
2017-11-05 20:47:39 +00:00
|
|
|
before_install:
|
|
|
|
- sudo sysctl -w net.ipv6.conf.all.disable_ipv6=0
|
|
|
|
|
2013-01-10 07:16:20 +00:00
|
|
|
notifications:
|
|
|
|
email: false
|
2012-11-12 22:26:17 +00:00
|
|
|
language: c #NOTE: this will set CC=gcc which might cause trouble
|
|
|
|
before_script:
|
2014-07-05 19:18:00 +00:00
|
|
|
- WGET="travis_retry wget --continue --tries=20 --waitretry=10 --retry-connrefused --no-dns-cache --timeout 300"
|
2014-07-05 19:08:54 +00:00
|
|
|
- sudo apt-get -qq update
|
|
|
|
|
2014-10-14 08:03:28 +00:00
|
|
|
## Support building a binary that is identical to the CI
|
2017-11-13 15:23:43 +00:00
|
|
|
- echo -n "Contiki-NG will be compiled with RELSTR=" ; git --git-dir .git describe --tags --always
|
|
|
|
|
|
|
|
## Install 32-bit compatibility libraries
|
|
|
|
- sudo apt-get -qq install libc6:i386 libgcc1:i386 gcc-4.6-base:i386
|
|
|
|
libstdc++5:i386 libstdc++6:i386 lib32z1
|
2014-10-14 08:00:28 +00:00
|
|
|
|
2014-11-18 16:43:38 +00:00
|
|
|
## Install doxygen
|
|
|
|
- if [ ${BUILD_CATEGORY:-0} = doxygen ] ; then
|
2017-05-13 11:09:58 +00:00
|
|
|
sudo add-apt-repository ppa:libreoffice/ppa -y && sudo apt-get -qq update &&
|
2014-11-18 16:43:38 +00:00
|
|
|
sudo apt-get --no-install-suggests --no-install-recommends -qq install doxygen &&
|
|
|
|
doxygen --version ;
|
|
|
|
fi
|
|
|
|
|
2014-07-05 19:08:54 +00:00
|
|
|
## Install msp430 toolchain
|
2017-11-13 15:23:43 +00:00
|
|
|
- if [ ${BUILD_ARCH:-0} = msp430 ] ; then
|
|
|
|
$WGET http://simonduq.github.io/resources/mspgcc-4.7.2-compiled.tar.bz2 &&
|
|
|
|
tar xjf mspgcc*.tar.bz2 -C /tmp/ &&
|
|
|
|
sudo cp -f -r /tmp/msp430/* /usr/local/ &&
|
|
|
|
rm -rf /tmp/msp430 mspgcc*.tar.bz2 &&
|
|
|
|
msp430-gcc --version ;
|
|
|
|
fi
|
2013-08-07 11:55:33 +00:00
|
|
|
|
2016-04-06 13:02:51 +00:00
|
|
|
## Install mainline ARM toolchain and srecord.
|
2015-02-17 00:07:07 +00:00
|
|
|
- if [ ${BUILD_ARCH:-0} = arm-aapcs ] ; then
|
2016-04-06 13:02:51 +00:00
|
|
|
sudo apt-get -qq install srecord &&
|
|
|
|
$WGET https://launchpad.net/gcc-arm-embedded/5.0/5-2015-q4-major/+download/gcc-arm-none-eabi-5_2-2015q4-20151219-linux.tar.bz2 &&
|
|
|
|
tar xjf gcc-arm-none-eabi-5_2-2015q4-20151219-linux.tar.bz2 -C /tmp/ &&
|
|
|
|
sudo cp -f -r /tmp/gcc-arm-none-eabi-5_2-2015q4/* /usr/local/ &&
|
|
|
|
rm -rf /tmp/gcc-arm-none-eabi-* gcc-arm-none-eabi-*-linux.tar.bz2 &&
|
2014-07-06 01:48:56 +00:00
|
|
|
arm-none-eabi-gcc --version ;
|
|
|
|
fi
|
|
|
|
|
2015-09-21 09:02:16 +00:00
|
|
|
## Install NXP toolchain
|
|
|
|
- if [ ${BUILD_ARCH:-0} = jn516x ] ; then
|
|
|
|
$WGET http://simonduq.github.io/resources/ba-elf-gcc-4.7.4-part1.tar.bz2 &&
|
|
|
|
$WGET http://simonduq.github.io/resources/ba-elf-gcc-4.7.4-part2.tar.bz2 &&
|
2017-03-08 10:24:35 +00:00
|
|
|
$WGET http://simonduq.github.io/resources/jn516x-sdk-4163-1416.tar.bz2 &&
|
2015-09-21 09:02:16 +00:00
|
|
|
mkdir /tmp/jn516x-sdk /tmp/ba-elf-gcc &&
|
|
|
|
tar xjf jn516x-sdk-*.tar.bz2 -C /tmp/jn516x-sdk &&
|
|
|
|
tar xjf ba-elf-gcc-*part1.tar.bz2 -C /tmp/ba-elf-gcc &&
|
|
|
|
tar xjf ba-elf-gcc-*part2.tar.bz2 -C /tmp/ba-elf-gcc &&
|
|
|
|
sudo cp -f -r /tmp/jn516x-sdk /usr/ &&
|
|
|
|
sudo cp -f -r /tmp/ba-elf-gcc /usr/ &&
|
|
|
|
export PATH=/usr/ba-elf-gcc/bin:$PATH &&
|
|
|
|
rm -rf /tmp/ba-elf-gcc* /tmp/jn516x-sdk* &&
|
|
|
|
ba-elf-gcc --version ;
|
|
|
|
fi
|
2017-05-13 11:09:58 +00:00
|
|
|
|
2016-01-22 10:13:07 +00:00
|
|
|
## Install mainline ARM toolchain and download nRF52 SDK
|
|
|
|
- if [ ${BUILD_ARCH:-0} = nrf52dk ] ; then
|
2016-06-02 07:32:24 +00:00
|
|
|
sudo add-apt-repository -y ppa:team-gcc-arm-embedded/ppa &&
|
2016-01-22 10:13:07 +00:00
|
|
|
sudo apt-get -qq update &&
|
2016-06-02 07:32:24 +00:00
|
|
|
sudo apt-get -qq install gcc-arm-embedded srecord &&
|
2016-01-22 10:13:07 +00:00
|
|
|
arm-none-eabi-gcc --version &&
|
|
|
|
$WGET https://developer.nordicsemi.com/nRF5_IoT_SDK/nRF5_IoT_SDK_v0.9.x/nrf5_iot_sdk_3288530.zip &&
|
|
|
|
mkdir /tmp/nrf52-sdk &&
|
|
|
|
unzip nrf5_iot_sdk_3288530.zip -d /tmp/nrf52-sdk &&
|
|
|
|
export NRF52_SDK_ROOT=/tmp/nrf52-sdk ;
|
|
|
|
fi
|
2015-09-21 09:02:16 +00:00
|
|
|
|
2012-11-13 00:07:04 +00:00
|
|
|
## Compile cooja.jar only when it's going to be needed
|
2017-05-15 14:58:13 +00:00
|
|
|
- if [ ${BUILD_CATEGORY:-0} = sim ] ; then
|
2014-07-05 19:08:54 +00:00
|
|
|
java -version &&
|
|
|
|
ant -q -f tools/cooja/build.xml jar &&
|
|
|
|
sudo java -Xshare:dump -version ;
|
|
|
|
fi
|
2012-11-12 22:26:17 +00:00
|
|
|
|
|
|
|
script:
|
2017-09-01 14:39:58 +00:00
|
|
|
## tests/Makefile handles most of generic logic
|
2017-11-05 13:57:31 +00:00
|
|
|
- "make -C tests/??-$BUILD_TYPE summary"
|
2012-11-12 22:26:17 +00:00
|
|
|
|
|
|
|
after_script:
|
2013-05-18 01:07:12 +00:00
|
|
|
## Print cooja test logs
|
2017-11-13 15:21:23 +00:00
|
|
|
- "[ ${BUILD_CATEGORY:-0} = sim ] && tail tests/??-$BUILD_TYPE/*.scriptlog"
|
2014-07-06 01:48:56 +00:00
|
|
|
## Print a basic summary
|
2017-09-01 14:39:58 +00:00
|
|
|
- "echo 'Summary:'; cat tests/??-$BUILD_TYPE/summary"
|
|
|
|
- "FAILS=`grep -c ' FAIL ' tests/??-$BUILD_TYPE/summary`"
|
2012-11-12 22:26:17 +00:00
|
|
|
## This will detect whether the build should pass or fail
|
2012-12-17 11:34:58 +00:00
|
|
|
- "test $FAILS -eq 0; exit $?"
|
2012-11-12 22:26:17 +00:00
|
|
|
|
|
|
|
|
|
|
|
env:
|
|
|
|
## This magically kick-off parallel jobs for each of the for the sets
|
|
|
|
## of environment variable defined below
|
2017-05-15 14:58:13 +00:00
|
|
|
- BUILD_TYPE='doxygen' BUILD_CATEGORY='doxygen'
|
2017-11-13 15:23:43 +00:00
|
|
|
- BUILD_TYPE='compile-base' BUILD_CATEGORY='compile' BUILD_ARCH='msp430'
|
2015-02-17 00:07:07 +00:00
|
|
|
- BUILD_TYPE='compile-arm-ports' BUILD_CATEGORY='compile' BUILD_ARCH='arm-aapcs'
|
2015-09-21 09:02:16 +00:00
|
|
|
- BUILD_TYPE='compile-nxp-ports' BUILD_CATEGORY='compile' BUILD_ARCH='jn516x'
|
2016-01-22 10:13:07 +00:00
|
|
|
- BUILD_TYPE='compile-nrf52-ports' BUILD_CATEGORY='compile' BUILD_ARCH='nrf52dk'
|
2017-05-13 11:09:58 +00:00
|
|
|
- BUILD_TYPE='compile-tools' BUILD_CATEGORY='compile'
|
2017-06-10 12:35:39 +00:00
|
|
|
- BUILD_TYPE='rpl-lite' BUILD_CATEGORY='sim'
|
2017-09-17 08:14:37 +00:00
|
|
|
- BUILD_TYPE='rpl-classic' BUILD_CATEGORY='sim'
|
2017-11-13 15:23:43 +00:00
|
|
|
- BUILD_TYPE='ipv6' BUILD_CATEGORY='sim' BUILD_ARCH='msp430'
|
2017-09-15 15:54:03 +00:00
|
|
|
- BUILD_TYPE='nullnet' BUILD_CATEGORY='sim'
|
2017-11-13 15:23:43 +00:00
|
|
|
- BUILD_TYPE='base' BUILD_CATEGORY='sim' BUILD_ARCH='msp430'
|
2017-05-15 14:58:13 +00:00
|
|
|
- BUILD_TYPE='ieee802154' BUILD_CATEGORY='sim'
|
2016-11-02 13:12:07 +00:00
|
|
|
- BUILD_TYPE='6tisch' BUILD_CATEGORY='sim'
|
2017-11-05 20:47:39 +00:00
|
|
|
- BUILD_TYPE='rpl-border-router' BUILD_CATEGORY='sim'
|
2017-11-10 21:57:32 +00:00
|
|
|
- BUILD_TYPE='native-networking' BUILD_CATEGORY='sim'
|