2018-07-17 22:39:39 -04:00
|
|
|
# global options
|
2019-02-11 18:55:48 -05:00
|
|
|
dist: xenial
|
2018-07-17 22:39:39 -04:00
|
|
|
language:
|
|
|
|
- c
|
2014-04-14 14:05:47 -04:00
|
|
|
compiler:
|
|
|
|
- gcc
|
2016-10-25 04:07:29 -04:00
|
|
|
cache:
|
|
|
|
directories:
|
|
|
|
- "${HOME}/persist"
|
2018-03-08 19:34:46 -05:00
|
|
|
env:
|
2018-07-17 22:39:39 -04:00
|
|
|
global:
|
|
|
|
- MAKEOPTS="-j4"
|
2019-06-23 22:05:17 -04:00
|
|
|
git:
|
|
|
|
submodules: false
|
2014-04-14 14:05:47 -04:00
|
|
|
|
2018-07-17 22:39:39 -04:00
|
|
|
# define the successive stages
|
|
|
|
stages:
|
|
|
|
- name: test
|
2014-04-14 14:05:47 -04:00
|
|
|
|
2018-07-17 22:39:39 -04:00
|
|
|
# define the jobs for the stages
|
2020-02-26 23:41:11 -05:00
|
|
|
# approx order of the jobs has longest running first to optimise total time
|
2018-07-17 22:39:39 -04:00
|
|
|
jobs:
|
|
|
|
include:
|
2020-02-26 23:41:11 -05:00
|
|
|
# check code formatting
|
|
|
|
- stage: test
|
|
|
|
os: linux
|
|
|
|
dist: bionic
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "code formatting"
|
2020-03-08 21:26:35 -04:00
|
|
|
before_install:
|
|
|
|
- sudo apt-add-repository --yes --update ppa:pybricks/ppa
|
2020-02-26 23:41:11 -05:00
|
|
|
install:
|
2020-03-08 21:26:35 -04:00
|
|
|
- sudo apt-get install uncrustify python3-pip
|
|
|
|
- uncrustify --version
|
|
|
|
- pip3 install --user black
|
2020-02-26 23:41:11 -05:00
|
|
|
- black --version
|
|
|
|
script:
|
2020-03-08 21:26:35 -04:00
|
|
|
- tools/codeformat.py
|
2020-02-26 23:41:11 -05:00
|
|
|
- git diff --exit-code
|
|
|
|
|
2020-04-09 02:28:03 -04:00
|
|
|
# unix port on OSX (first in list because the build VM takes a long time to start)
|
|
|
|
- stage: test
|
|
|
|
os: osx
|
|
|
|
osx_image: xcode11.3
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "unix port build with clang on OSX"
|
2020-04-09 02:28:03 -04:00
|
|
|
env:
|
|
|
|
- PKG_CONFIG_PATH=/usr/local/opt/libffi/lib/pkgconfig
|
|
|
|
script:
|
|
|
|
- make ${MAKEOPTS} -C mpy-cross
|
|
|
|
- make ${MAKEOPTS} -C ports/unix submodules
|
|
|
|
- make ${MAKEOPTS} -C ports/unix deplibs
|
|
|
|
- make ${MAKEOPTS} -C ports/unix
|
|
|
|
# OSX has poor time resolution and the following tests do not have the correct output
|
|
|
|
- (cd tests && ./run-tests --exclude 'uasyncio_(basic|heaplock|lock|wait_task)')
|
|
|
|
# check for additional compiler errors/warnings
|
2020-04-19 21:50:02 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix VARIANT=coverage submodules
|
2020-04-09 02:28:03 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix VARIANT=coverage
|
|
|
|
after_failure:
|
|
|
|
- tests/run-tests --print-failures
|
|
|
|
|
2018-07-17 22:39:39 -04:00
|
|
|
# stm32 port
|
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "stm32 port build"
|
2018-07-17 22:39:39 -04:00
|
|
|
install:
|
|
|
|
# need newer gcc version for Cortex-M7 support
|
2019-02-11 18:55:48 -05:00
|
|
|
- sudo add-apt-repository -y ppa:team-gcc-arm-embedded/ppa
|
2018-07-17 22:39:39 -04:00
|
|
|
- sudo apt-get update -qq || true
|
2020-05-25 23:54:19 -04:00
|
|
|
- sudo apt-get install gcc-arm-embedded libnewlib-arm-none-eabi
|
2018-07-17 22:39:39 -04:00
|
|
|
- arm-none-eabi-gcc --version
|
|
|
|
script:
|
|
|
|
- make ${MAKEOPTS} -C mpy-cross
|
2019-10-13 21:09:39 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/stm32 submodules
|
2020-02-19 22:46:17 -05:00
|
|
|
- git submodule update --init lib/btstack
|
2019-09-25 21:19:08 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/stm32 BOARD=NUCLEO_F091RC
|
2018-07-17 22:39:39 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/stm32 BOARD=PYBV11 MICROPY_PY_WIZNET5K=5200 MICROPY_PY_CC3K=1
|
2019-05-31 08:47:00 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/stm32 BOARD=PYBD_SF2
|
2020-02-19 22:46:17 -05:00
|
|
|
- make ${MAKEOPTS} -C ports/stm32 BOARD=PYBD_SF6 NANBOX=1 MICROPY_BLUETOOTH_NIMBLE=0 MICROPY_BLUETOOTH_BTSTACK=1
|
2019-09-25 21:19:08 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/stm32 BOARD=NUCLEO_H743ZI CFLAGS_EXTRA='-DMICROPY_PY_THREAD=1'
|
2020-03-27 22:54:28 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/stm32 BOARD=NUCLEO_L073RZ
|
2018-07-17 22:39:39 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/stm32 BOARD=STM32L476DISC
|
2019-09-25 21:19:08 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/stm32 BOARD=NUCLEO_WB55
|
2019-07-08 21:47:57 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/stm32/mboot BOARD=PYBD_SF6
|
2014-05-11 13:33:13 -04:00
|
|
|
|
2018-07-17 22:39:39 -04:00
|
|
|
# qemu-arm port
|
|
|
|
- stage: test
|
2020-03-01 23:03:10 -05:00
|
|
|
dist: bionic # needed for more recent version of qemu-system-arm with mps2-an385 target
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "qemu-arm port build and tests"
|
2018-07-17 22:39:39 -04:00
|
|
|
install:
|
2020-05-25 23:54:19 -04:00
|
|
|
- sudo apt-get install gcc-arm-none-eabi libnewlib-arm-none-eabi qemu-system
|
2018-07-17 22:39:39 -04:00
|
|
|
- arm-none-eabi-gcc --version
|
2019-02-11 18:55:48 -05:00
|
|
|
- qemu-system-arm --version
|
2018-07-17 22:39:39 -04:00
|
|
|
script:
|
|
|
|
- make ${MAKEOPTS} -C mpy-cross
|
|
|
|
- make ${MAKEOPTS} -C ports/qemu-arm -f Makefile.test test
|
|
|
|
after_failure:
|
2020-03-27 00:26:18 -04:00
|
|
|
- grep --text "FAIL" ports/qemu-arm/build/console.out
|
2015-03-01 08:37:27 -05:00
|
|
|
|
2018-07-17 22:39:39 -04:00
|
|
|
# unix coverage
|
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "unix coverage build and tests"
|
2018-07-17 22:39:39 -04:00
|
|
|
install:
|
2019-12-12 01:45:02 -05:00
|
|
|
- sudo apt-get install python3-pip
|
2018-07-17 22:39:39 -04:00
|
|
|
- sudo pip install cpp-coveralls
|
2019-12-12 01:45:02 -05:00
|
|
|
- sudo pip3 install setuptools
|
|
|
|
- sudo pip3 install pyelftools
|
2018-07-17 22:39:39 -04:00
|
|
|
- gcc --version
|
|
|
|
- python3 --version
|
|
|
|
script:
|
|
|
|
- make ${MAKEOPTS} -C mpy-cross
|
2020-04-19 21:50:02 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix VARIANT=coverage submodules
|
|
|
|
- make ${MAKEOPTS} -C ports/unix VARIANT=coverage deplibs
|
2019-10-22 22:50:09 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix VARIANT=coverage
|
2018-07-17 22:39:39 -04:00
|
|
|
# run the main test suite
|
2020-03-11 02:03:44 -04:00
|
|
|
- make -C ports/unix VARIANT=coverage test_full
|
2020-04-09 08:50:55 -04:00
|
|
|
- (cd tests && MICROPY_CPYTHON3=python3 MICROPY_MICROPYTHON=../ports/unix/micropython-coverage ./run-multitests.py multi_net/*.py) || travis_terminate 1
|
2019-12-12 01:45:02 -05:00
|
|
|
# test building native mpy modules
|
|
|
|
- make -C examples/natmod/features1 ARCH=x64
|
|
|
|
- make -C examples/natmod/features2 ARCH=x64
|
|
|
|
- make -C examples/natmod/btree ARCH=x64
|
|
|
|
- make -C examples/natmod/framebuf ARCH=x64
|
|
|
|
- make -C examples/natmod/uheapq ARCH=x64
|
2019-12-12 21:32:15 -05:00
|
|
|
- make -C examples/natmod/urandom ARCH=x64
|
2019-12-12 01:45:02 -05:00
|
|
|
- make -C examples/natmod/ure ARCH=x64
|
|
|
|
- make -C examples/natmod/uzlib ARCH=x64
|
|
|
|
# test importing .mpy generated by mpy_ld.py
|
2019-10-30 02:00:09 -04:00
|
|
|
- MICROPYPATH=examples/natmod/features2 ./ports/unix/micropython-coverage -m features2
|
2019-12-12 01:45:02 -05:00
|
|
|
- (cd tests && ./run-natmodtests.py extmod/{btree*,framebuf*,uheapq*,ure*,uzlib*}.py)
|
2018-07-17 22:39:39 -04:00
|
|
|
# run coveralls coverage analysis (try to, even if some builds/tests failed)
|
|
|
|
- (cd ports/unix && coveralls --root ../.. --build-root . --gcov $(which gcov) --gcov-options '\-o build-coverage/' --include py --include extmod)
|
|
|
|
after_failure:
|
2020-03-26 23:41:38 -04:00
|
|
|
- tests/run-tests --print-failures
|
2015-03-01 08:37:27 -05:00
|
|
|
|
2019-12-22 06:22:14 -05:00
|
|
|
# unix coverage 32-bit
|
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "unix coverage 32-bit build and tests"
|
2019-12-22 06:22:14 -05:00
|
|
|
install:
|
|
|
|
- sudo apt-get install gcc-multilib libffi-dev:i386
|
|
|
|
- sudo apt-get install python3-pip
|
|
|
|
- sudo pip3 install setuptools
|
|
|
|
- sudo pip3 install pyelftools
|
|
|
|
- gcc --version
|
|
|
|
- python3 --version
|
|
|
|
script:
|
|
|
|
- make ${MAKEOPTS} -C mpy-cross
|
2020-04-19 21:50:02 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix MICROPY_FORCE_32BIT=1 VARIANT=coverage submodules
|
|
|
|
- make ${MAKEOPTS} -C ports/unix MICROPY_FORCE_32BIT=1 VARIANT=coverage deplibs
|
2020-02-10 21:29:25 -05:00
|
|
|
- make ${MAKEOPTS} -C ports/unix MICROPY_FORCE_32BIT=1 VARIANT=coverage
|
2019-12-22 06:22:14 -05:00
|
|
|
# run the main test suite
|
2020-04-09 08:50:55 -04:00
|
|
|
- make -C ports/unix MICROPY_FORCE_32BIT=1 VARIANT=coverage test_full || travis_terminate 1
|
2019-12-22 06:22:14 -05:00
|
|
|
# test building native mpy modules
|
|
|
|
- make -C examples/natmod/features1 ARCH=x86
|
|
|
|
- make -C examples/natmod/features2 ARCH=x86
|
|
|
|
- make -C examples/natmod/btree ARCH=x86
|
|
|
|
- make -C examples/natmod/framebuf ARCH=x86
|
|
|
|
- make -C examples/natmod/uheapq ARCH=x86
|
|
|
|
- make -C examples/natmod/urandom ARCH=x86
|
|
|
|
- make -C examples/natmod/ure ARCH=x86
|
|
|
|
- make -C examples/natmod/uzlib ARCH=x86
|
|
|
|
# test importing .mpy generated by mpy_ld.py
|
2019-10-30 02:00:09 -04:00
|
|
|
- MICROPYPATH=examples/natmod/features2 ./ports/unix/micropython-coverage -m features2
|
2019-12-22 06:22:14 -05:00
|
|
|
- (cd tests && ./run-natmodtests.py --arch x86 extmod/{btree*,framebuf*,uheapq*,ure*,uzlib*}.py)
|
|
|
|
after_failure:
|
2020-03-26 23:41:38 -04:00
|
|
|
- tests/run-tests --print-failures
|
2019-12-22 06:22:14 -05:00
|
|
|
|
2018-07-17 22:39:39 -04:00
|
|
|
# standard unix port
|
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "unix port build and tests"
|
2018-07-17 22:39:39 -04:00
|
|
|
script:
|
|
|
|
- make ${MAKEOPTS} -C mpy-cross
|
2019-10-13 21:09:39 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix submodules
|
2018-07-17 22:39:39 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix deplibs
|
|
|
|
- make ${MAKEOPTS} -C ports/unix
|
|
|
|
- make ${MAKEOPTS} -C ports/unix test
|
2019-06-26 00:29:06 -04:00
|
|
|
- (cd tests && MICROPY_CPYTHON3=python3 MICROPY_MICROPYTHON=../ports/unix/micropython ./run-perfbench.py 1000 1000)
|
2020-03-26 23:41:38 -04:00
|
|
|
after_failure:
|
|
|
|
- tests/run-tests --print-failures
|
2018-02-07 19:30:19 -05:00
|
|
|
|
2020-04-09 07:59:11 -04:00
|
|
|
# unix nanbox/float (and using Python 2 to check it can run the build scripts)
|
2018-07-17 22:39:39 -04:00
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "unix nanbox/float port build and tests"
|
2018-07-17 22:39:39 -04:00
|
|
|
install:
|
|
|
|
- sudo apt-get install gcc-multilib libffi-dev:i386
|
|
|
|
script:
|
2019-09-30 22:51:57 -04:00
|
|
|
- make ${MAKEOPTS} -C mpy-cross PYTHON=python2
|
2020-04-19 21:50:02 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix VARIANT=nanbox submodules
|
|
|
|
- make ${MAKEOPTS} -C ports/unix PYTHON=python2 VARIANT=nanbox deplibs
|
2019-10-22 22:50:09 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix PYTHON=python2 VARIANT=nanbox
|
2020-04-09 07:59:11 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix PYTHON=python2 VARIANT=nanbox test_full || travis_terminate 1
|
|
|
|
- make ${MAKEOPTS} -C ports/unix clean
|
|
|
|
- make ${MAKEOPTS} -C ports/unix CFLAGS_EXTRA="-DMICROPY_FLOAT_IMPL=MICROPY_FLOAT_IMPL_FLOAT"
|
|
|
|
- make ${MAKEOPTS} -C ports/unix test
|
2020-03-26 23:41:38 -04:00
|
|
|
after_failure:
|
|
|
|
- tests/run-tests --print-failures
|
2014-04-15 07:52:59 -04:00
|
|
|
|
2020-04-09 07:59:11 -04:00
|
|
|
# unix stackless/float with clang
|
2018-07-17 22:39:39 -04:00
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "unix stackless/float port build and tests with clang"
|
2019-07-08 03:18:47 -04:00
|
|
|
install:
|
|
|
|
- sudo apt-get install clang
|
2018-07-17 22:39:39 -04:00
|
|
|
script:
|
2019-07-08 03:18:47 -04:00
|
|
|
- make ${MAKEOPTS} -C mpy-cross CC=clang
|
2019-10-13 21:09:39 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix submodules
|
2019-07-08 03:18:47 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix CC=clang CFLAGS_EXTRA="-DMICROPY_STACKLESS=1 -DMICROPY_STACKLESS_STRICT=1"
|
2020-04-09 07:59:11 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix CC=clang test || travis_terminate 1
|
|
|
|
- make ${MAKEOPTS} -C ports/unix clean
|
|
|
|
- make ${MAKEOPTS} -C ports/unix CC=clang CFLAGS_EXTRA="-DMICROPY_FLOAT_IMPL=MICROPY_FLOAT_IMPL_FLOAT"
|
2019-07-08 03:18:47 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix CC=clang test
|
2020-03-26 23:41:38 -04:00
|
|
|
after_failure:
|
|
|
|
- tests/run-tests --print-failures
|
2017-12-16 13:43:30 -05:00
|
|
|
|
2019-08-27 01:43:10 -04:00
|
|
|
# unix with sys.settrace
|
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "unix port with sys.settrace build and tests"
|
2019-08-27 01:43:10 -04:00
|
|
|
script:
|
|
|
|
- make ${MAKEOPTS} -C mpy-cross
|
2020-04-09 08:50:55 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix MICROPY_PY_BTREE=0 MICROPY_PY_FFI=0 MICROPY_PY_USSL=0 CFLAGS_EXTRA="-DMICROPY_PY_SYS_SETTRACE=1" test || travis_terminate 1
|
2019-08-27 01:43:10 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/unix clean
|
|
|
|
- make ${MAKEOPTS} -C ports/unix MICROPY_PY_BTREE=0 MICROPY_PY_FFI=0 MICROPY_PY_USSL=0 CFLAGS_EXTRA="-DMICROPY_STACKLESS=1 -DMICROPY_STACKLESS_STRICT=1 -DMICROPY_PY_SYS_SETTRACE=1" test
|
|
|
|
after_failure:
|
2020-03-26 23:41:38 -04:00
|
|
|
- tests/run-tests --print-failures
|
2019-08-27 01:43:10 -04:00
|
|
|
|
2019-10-29 07:23:00 -04:00
|
|
|
# minimal unix port with tests
|
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "minimal unix port build and tests"
|
2019-10-29 07:23:00 -04:00
|
|
|
script:
|
2020-02-10 21:29:25 -05:00
|
|
|
- make ${MAKEOPTS} -C ports/unix VARIANT=minimal
|
2019-10-30 02:00:09 -04:00
|
|
|
- (cd tests && MICROPY_CPYTHON3=python3 MICROPY_MICROPYTHON=../ports/unix/micropython-minimal ./run-tests -e exception_chain -e self_type_check -e subclass_native_init -d basics)
|
2020-03-26 23:41:38 -04:00
|
|
|
after_failure:
|
|
|
|
- tests/run-tests --print-failures
|
2020-02-20 04:21:29 -05:00
|
|
|
|
2018-07-17 22:39:39 -04:00
|
|
|
# windows port via mingw
|
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "windows port build via mingw"
|
2018-07-17 22:39:39 -04:00
|
|
|
install:
|
|
|
|
- sudo apt-get install gcc-mingw-w64
|
|
|
|
script:
|
|
|
|
- make ${MAKEOPTS} -C mpy-cross
|
|
|
|
- make ${MAKEOPTS} -C ports/windows CROSS_COMPILE=i686-w64-mingw32-
|
|
|
|
|
2020-04-11 11:51:37 -04:00
|
|
|
# esp32 w/ESP-IDFv3 port
|
2019-06-24 21:18:36 -04:00
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "esp32 ESP-IDFv3 port build"
|
2019-06-24 21:18:36 -04:00
|
|
|
install:
|
|
|
|
- sudo apt-get install python3-pip
|
2019-09-13 09:48:28 -04:00
|
|
|
- sudo pip3 install 'pyparsing<2.4'
|
2020-04-11 11:51:37 -04:00
|
|
|
- curl -L https://dl.espressif.com/dl/xtensa-esp32-elf-linux64-1.22.0-80-g6c4433a-5.2.0.tar.gz | tar zxf -
|
2019-06-24 21:18:36 -04:00
|
|
|
- export PATH=$(pwd)/xtensa-esp32-elf/bin:$PATH
|
|
|
|
- git clone https://github.com/espressif/esp-idf.git
|
2019-09-13 09:48:28 -04:00
|
|
|
- export IDF_PATH=$(pwd)/esp-idf
|
2019-06-24 21:18:36 -04:00
|
|
|
script:
|
|
|
|
- make ${MAKEOPTS} -C mpy-cross
|
2019-09-13 09:48:28 -04:00
|
|
|
- git -C esp-idf checkout $(grep "ESPIDF_SUPHASH_V3 :=" ports/esp32/Makefile | cut -d " " -f 3)
|
2019-12-15 20:36:38 -05:00
|
|
|
- git -C esp-idf submodule update --init components/json/cJSON components/esp32/lib components/esptool_py/esptool components/expat/expat components/lwip/lwip components/mbedtls/mbedtls components/micro-ecc/micro-ecc components/nghttp/nghttp2 components/nimble components/bt
|
2019-10-13 21:09:39 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/esp32 submodules
|
2019-09-13 09:48:28 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/esp32
|
2020-04-11 11:51:37 -04:00
|
|
|
|
|
|
|
# esp32 w/ESP-IDFv4 port
|
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "esp32 ESP-IDFv4 port build"
|
2020-04-11 11:51:37 -04:00
|
|
|
install:
|
|
|
|
- sudo apt-get install python3-pip
|
|
|
|
- sudo pip3 install 'pyparsing<2.4'
|
|
|
|
- curl -L https://dl.espressif.com/dl/xtensa-esp32-elf-gcc8_2_0-esp-2019r2-linux-amd64.tar.gz | tar zxf -
|
|
|
|
- export PATH=$(pwd)/xtensa-esp32-elf/bin:$PATH
|
|
|
|
- git clone https://github.com/espressif/esp-idf.git
|
|
|
|
- export IDF_PATH=$(pwd)/esp-idf
|
|
|
|
script:
|
|
|
|
- make ${MAKEOPTS} -C mpy-cross
|
2019-09-13 09:48:28 -04:00
|
|
|
- git -C esp-idf checkout $(grep "ESPIDF_SUPHASH_V4 :=" ports/esp32/Makefile | cut -d " " -f 3)
|
2019-10-07 23:27:44 -04:00
|
|
|
- git -C esp-idf submodule update --init components/bt/controller/lib components/bt/host/nimble/nimble components/esp_wifi/lib_esp32 components/esptool_py/esptool components/lwip/lwip components/mbedtls/mbedtls
|
2019-10-13 21:09:39 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/esp32 submodules
|
2019-09-13 09:48:28 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/esp32
|
2019-06-24 21:18:36 -04:00
|
|
|
|
2019-06-23 22:52:34 -04:00
|
|
|
# esp8266 port
|
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "esp8266 port build"
|
2019-06-23 22:52:34 -04:00
|
|
|
install:
|
|
|
|
- wget https://github.com/jepler/esp-open-sdk/releases/download/2018-06-10/xtensa-lx106-elf-standalone.tar.gz
|
|
|
|
- zcat xtensa-lx106-elf-standalone.tar.gz | tar x
|
|
|
|
- export PATH=$(pwd)/xtensa-lx106-elf/bin:$PATH
|
|
|
|
script:
|
|
|
|
- make ${MAKEOPTS} -C mpy-cross
|
2019-10-13 21:09:39 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/esp8266 submodules
|
2019-06-23 22:52:34 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/esp8266
|
2019-09-30 03:26:41 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/esp8266 BOARD=GENERIC_512K
|
2020-04-04 01:37:51 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/esp8266 BOARD=GENERIC_1M
|
2019-06-23 22:52:34 -04:00
|
|
|
|
2018-07-18 20:36:38 -04:00
|
|
|
# nrf port
|
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "nrf port build"
|
2018-07-18 20:36:38 -04:00
|
|
|
install:
|
2019-02-11 18:55:48 -05:00
|
|
|
- sudo apt-get install gcc-arm-none-eabi
|
|
|
|
- sudo apt-get install libnewlib-arm-none-eabi
|
2018-07-18 20:36:38 -04:00
|
|
|
- arm-none-eabi-gcc --version
|
|
|
|
script:
|
2019-10-13 21:09:39 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/nrf submodules
|
2020-03-25 02:08:21 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/nrf BOARD=pca10040
|
|
|
|
- make ${MAKEOPTS} -C ports/nrf BOARD=microbit
|
|
|
|
- make ${MAKEOPTS} -C ports/nrf BOARD=pca10056
|
2018-07-18 20:36:38 -04:00
|
|
|
|
2020-04-18 19:16:36 -04:00
|
|
|
# bare-arm and minimal ports, with size-diff check
|
2018-07-17 22:39:39 -04:00
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "bare-arm and minimal ports build and size-diff check"
|
2018-07-17 22:39:39 -04:00
|
|
|
install:
|
2020-05-25 23:54:19 -04:00
|
|
|
- sudo apt-get install gcc-multilib libffi-dev:i386 gcc-arm-none-eabi libnewlib-arm-none-eabi
|
2020-04-18 19:16:36 -04:00
|
|
|
- gcc --version
|
2018-07-17 22:39:39 -04:00
|
|
|
- arm-none-eabi-gcc --version
|
|
|
|
script:
|
2020-04-29 21:18:32 -04:00
|
|
|
# starts off at either the ref/pull/N/merge FETCH_HEAD, or the current branch HEAD
|
|
|
|
- git checkout -b pull_request # save the current location
|
|
|
|
- git remote add upstream https://github.com/micropython/micropython.git
|
|
|
|
- git fetch --depth=100 upstream
|
|
|
|
# build reference, save to size0
|
|
|
|
# ignore any errors with this build, in case master is failing
|
|
|
|
- git checkout `git merge-base --fork-point upstream/master pull_request`
|
2020-04-18 19:16:36 -04:00
|
|
|
- git show -s
|
|
|
|
- tools/metrics.py clean bm
|
2020-04-29 21:18:32 -04:00
|
|
|
- tools/metrics.py build bm | tee ~/size0 || true
|
|
|
|
# build PR/branch, save to size1
|
2020-04-18 19:16:36 -04:00
|
|
|
- git checkout pull_request
|
2020-04-29 21:18:32 -04:00
|
|
|
- git log upstream/master..HEAD
|
2020-04-18 19:16:36 -04:00
|
|
|
- tools/metrics.py clean bm
|
|
|
|
- tools/metrics.py build bm | tee ~/size1 || travis_terminate 1
|
2020-04-29 21:18:32 -04:00
|
|
|
# compute diff of the code sizes
|
2020-04-18 19:16:36 -04:00
|
|
|
- tools/metrics.py diff --error-threshold 0 ~/size0 ~/size1
|
2018-07-17 22:39:39 -04:00
|
|
|
|
|
|
|
# cc3200 port
|
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "cc3200 port build"
|
2018-07-17 22:39:39 -04:00
|
|
|
install:
|
2020-05-25 23:54:19 -04:00
|
|
|
- sudo apt-get install gcc-arm-none-eabi libnewlib-arm-none-eabi
|
2018-07-17 22:39:39 -04:00
|
|
|
script:
|
|
|
|
- make ${MAKEOPTS} -C ports/cc3200 BTARGET=application BTYPE=release
|
|
|
|
- make ${MAKEOPTS} -C ports/cc3200 BTARGET=bootloader BTYPE=release
|
|
|
|
|
2019-06-22 09:06:42 -04:00
|
|
|
# samd port
|
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "samd port build"
|
2019-06-22 09:06:42 -04:00
|
|
|
install:
|
2020-05-25 23:54:19 -04:00
|
|
|
- sudo apt-get install gcc-arm-none-eabi libnewlib-arm-none-eabi
|
2019-06-22 09:06:42 -04:00
|
|
|
script:
|
2019-10-13 21:09:39 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/samd submodules
|
2019-06-22 09:06:42 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/samd
|
|
|
|
|
2018-07-17 22:39:39 -04:00
|
|
|
# teensy port
|
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "teensy port build"
|
2018-07-17 22:39:39 -04:00
|
|
|
install:
|
2020-05-25 23:54:19 -04:00
|
|
|
- sudo apt-get install gcc-arm-none-eabi libnewlib-arm-none-eabi
|
2018-07-17 22:39:39 -04:00
|
|
|
script:
|
|
|
|
- make ${MAKEOPTS} -C ports/teensy
|
2019-08-21 20:21:48 -04:00
|
|
|
|
|
|
|
# powerpc port
|
|
|
|
- stage: test
|
2020-05-25 23:57:33 -04:00
|
|
|
name: "powerpc port build"
|
2019-08-21 20:21:48 -04:00
|
|
|
install:
|
2020-05-25 23:54:19 -04:00
|
|
|
- sudo apt-get install gcc-powerpc64le-linux-gnu libc6-dev-ppc64el-cross
|
2019-08-21 20:21:48 -04:00
|
|
|
script:
|
2020-05-25 23:48:41 -04:00
|
|
|
- make ${MAKEOPTS} -C ports/powerpc UART=potato
|
|
|
|
- make ${MAKEOPTS} -C ports/powerpc UART=lpc_serial
|