mirror of https://github.com/ArduPilot/ardupilot
travis: support waf build
Currently, an associative array variable waf_supported_boards is used to trigger waf build only the currently supported boards. After the transition to the new build system is done, that variable can be removed. We're just building for now - there is a current issue related to the rotation for solo, and it turns out that the first unit test added as an example is for vector rotations. After that is solved we can use waf check, so that unit tests are run as well.
This commit is contained in:
parent
16eceec09f
commit
8456cb4532
|
@ -15,6 +15,7 @@ fi
|
|||
declare -A build_platforms
|
||||
declare -A build_concurrency
|
||||
declare -A build_extra_clean
|
||||
declare -A waf_supported_boards
|
||||
|
||||
build_platforms=( ["ArduPlane"]="navio raspilot minlure sitl linux px4-v2"
|
||||
["ArduCopter"]="navio raspilot minlure sitl linux px4-v2 px4-v4"
|
||||
|
@ -32,8 +33,12 @@ build_concurrency=(["navio"]="-j2"
|
|||
|
||||
build_extra_clean=(["px4-v2"]="make px4-cleandep")
|
||||
|
||||
# get list of boards supported by the waf build
|
||||
for board in $(./waf list_boards | head -n1); do waf_supported_boards[$board]=1; done
|
||||
|
||||
echo "Targets: $TRAVIS_BUILD_TARGET"
|
||||
for t in $TRAVIS_BUILD_TARGET; do
|
||||
echo "Starting make based build for target ${t}..."
|
||||
for v in ${!build_platforms[@]}; do
|
||||
if [[ ${build_platforms[$v]} != *$t* ]]; then
|
||||
continue
|
||||
|
@ -49,4 +54,11 @@ for t in $TRAVIS_BUILD_TARGET; do
|
|||
make $t ${build_concurrency[$t]}
|
||||
popd
|
||||
done
|
||||
|
||||
if [[ -n ${waf_supported_boards[$t]} ]]; then
|
||||
echo "Starting waf build for board ${t}..."
|
||||
./waf configure --board $t
|
||||
./waf clean
|
||||
./waf ${build_concurrency[$t]} build
|
||||
fi
|
||||
done
|
||||
|
|
Loading…
Reference in New Issue