mirror of https://github.com/Desuuuu/klipper.git
test: Add travis CI
Signed-off-by: Sebastian Meyer <ich@sebmeyer.de> Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
parent
58dd6d9106
commit
a6b0649cb1
|
@ -0,0 +1,20 @@
|
|||
language: c
|
||||
|
||||
addons:
|
||||
apt:
|
||||
sourceline: 'ppa:team-gcc-arm-embedded/ppa'
|
||||
packages:
|
||||
- gcc-avr
|
||||
- avr-libc
|
||||
- wget
|
||||
|
||||
env:
|
||||
- TARGET=atmega2560-16mhz
|
||||
- TARGET=atmega328-16mhz
|
||||
# - TARGET=beaglebone needs pru-gcc (not out of the box available on Ubuntu)
|
||||
- TARGET=hostsimulator
|
||||
- TARGET=linuxprocess
|
||||
- TARGET=sam3x8e GCC_SRC=https://developer.arm.com/-/media/Files/downloads/gnu-rm/7-2017q4/gcc-arm-none-eabi-7-2017-q4-major-linux.tar.bz2 GCC_DIR=gcc-arm-none-eabi-7-2017-q4-major
|
||||
|
||||
script: ./test/travis-build.sh
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
# Base config file for atmega2560
|
||||
CONFIG_MACH_AVR=y
|
||||
CONFIG_MACH_atmega2560=y
|
||||
CONFIG_CLOCK_FREQ=16000000
|
|
@ -0,0 +1,4 @@
|
|||
# Base config file for atmega328
|
||||
CONFIG_MACH_AVR=y
|
||||
CONFIG_MACH_atmega328=y
|
||||
CONFIG_CLOCK_FREQ=16000000
|
|
@ -0,0 +1,2 @@
|
|||
# Base config file for beaglebone
|
||||
CONFIG_MACH_PRU=y
|
|
@ -0,0 +1,2 @@
|
|||
# Base config file for host simulator
|
||||
CONFIG_MACH_SIMU=y
|
|
@ -0,0 +1,2 @@
|
|||
# Base config file for linux process
|
||||
CONFIG_MACH_LINUX=y
|
|
@ -0,0 +1,2 @@
|
|||
# Base config file for Atmel SAM3x8e ARM processor
|
||||
CONFIG_MACH_SAM3X8E=y
|
|
@ -0,0 +1,35 @@
|
|||
#!/bin/bash
|
||||
set -eux
|
||||
if [ -z ${TARGET+x} ]; then
|
||||
if [ -z ${1+x} ]; then
|
||||
echo "Need a TARGET as environment variable or first parameter!"
|
||||
exit 1
|
||||
else
|
||||
TARGET="$1"
|
||||
fi
|
||||
fi
|
||||
|
||||
echo "Target is '$TARGET'"
|
||||
make clean
|
||||
make distclean
|
||||
unset CC
|
||||
cp test/configs/${TARGET}.config .config
|
||||
make olddefconfig
|
||||
|
||||
if [ ! -z ${GCC_SRC+x} ]; then
|
||||
if [ -z ${GCC_DIR+x} ]; then
|
||||
echo "Need a GCC_DIR together with GCC_SRC!"
|
||||
exit 1
|
||||
fi
|
||||
if [ -e "$GCC_DIR" ]; then
|
||||
echo "Reusing GCC in '$GCC_DIR'"
|
||||
else
|
||||
echo "Getting GCC from '$GCC_SRC'"
|
||||
wget "$GCC_SRC"
|
||||
echo "Unpacking GCC to '$GCC_DIR'"
|
||||
tar xf $(basename "$GCC_SRC")
|
||||
fi
|
||||
export PATH=$GCC_DIR/bin:$PATH
|
||||
fi
|
||||
|
||||
make V=1
|
Loading…
Reference in New Issue