tools/autobuild: Use distinct directory for building stm32 variants.

Previous the build directory just used the board name, now make it use the
variant name too.

This shouldn't have any change because the existing directory should not
exist (all builds run by these scripts remove their build directory after
completion), but it makes debugging easier.

Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
This commit is contained in:
Jim Mussared 2022-09-08 13:55:50 +10:00 committed by Damien George
parent dec0ff7a10
commit 9070a24940

View File

@ -10,7 +10,7 @@ function do_build() {
for variant in `$MICROPY_AUTOBUILD_MAKE BOARD=$board query-variants | grep VARIANTS: | cut -d' ' -f2-`; do for variant in `$MICROPY_AUTOBUILD_MAKE BOARD=$board query-variants | grep VARIANTS: | cut -d' ' -f2-`; do
target=$descr-$variant target=$descr-$variant
echo "building $target $board" echo "building $target $board"
build_dir=/tmp/stm-build-$board build_dir=/tmp/stm-build-$board-$variant
$MICROPY_AUTOBUILD_MAKE $@ BOARD=$board BOARD_VARIANT=$variant BUILD=$build_dir || exit 1 $MICROPY_AUTOBUILD_MAKE $@ BOARD=$board BOARD_VARIANT=$variant BUILD=$build_dir || exit 1
mv $build_dir/firmware.dfu $dest_dir/$target$fw_tag.dfu mv $build_dir/firmware.dfu $dest_dir/$target$fw_tag.dfu
mv $build_dir/firmware.hex $dest_dir/$target$fw_tag.hex mv $build_dir/firmware.hex $dest_dir/$target$fw_tag.hex