mirror of
https://github.com/danbee/unicorn
synced 2026-06-20 22:52:22 +00:00
CI: Use correct baked examples directories.
This commit is contained in:
parent
9817f612eb
commit
637d989f45
@ -114,7 +114,11 @@ function ci_cmake_configure {
|
|||||||
function ci_cmake_build {
|
function ci_cmake_build {
|
||||||
BOARD=$1
|
BOARD=$1
|
||||||
MICROPY_BOARD_DIR=$CI_PROJECT_ROOT/boards/$BOARD
|
MICROPY_BOARD_DIR=$CI_PROJECT_ROOT/boards/$BOARD
|
||||||
EXAMPLES_DIR=$CI_PROJECT_ROOT/examples/launcher/
|
# Hack to deal with each board needing its own baked directory
|
||||||
|
# TODO: We should probably define some means to configure this
|
||||||
|
# Like using CMake to invoke dir2uf2
|
||||||
|
EXAMPLES_DIR="$(printf $BOARD | cut -d_ -f3)_unicorn/launch"
|
||||||
|
EXAMPLES_ROOT="$CI_PROJECT_ROOT/examples"
|
||||||
TOOLS_DIR=$CI_BUILD_ROOT/tools
|
TOOLS_DIR=$CI_BUILD_ROOT/tools
|
||||||
BUILD_DIR="$CI_BUILD_ROOT/build-$BOARD"
|
BUILD_DIR="$CI_BUILD_ROOT/build-$BOARD"
|
||||||
ccache --zero-stats || true
|
ccache --zero-stats || true
|
||||||
@ -129,7 +133,8 @@ function ci_cmake_build {
|
|||||||
|
|
||||||
if [ -f "$MICROPY_BOARD_DIR/manifest.txt" ] && [ -d "$TOOLS_DIR/dir2uf2" ]; then
|
if [ -f "$MICROPY_BOARD_DIR/manifest.txt" ] && [ -d "$TOOLS_DIR/dir2uf2" ]; then
|
||||||
log_inform "Creating $(pwd)/$BOARD-with-filesystem.uf2"
|
log_inform "Creating $(pwd)/$BOARD-with-filesystem.uf2"
|
||||||
|
log_inform "Using dir: $EXAMPLES_ROOT/$EXAMPLES_DIR"
|
||||||
python3 -m pip install littlefs-python==0.12.0
|
python3 -m pip install littlefs-python==0.12.0
|
||||||
$TOOLS_DIR/dir2uf2/dir2uf2 --fs-compact --sparse --append-to "$(pwd)/$BOARD.uf2" --manifest "$MICROPY_BOARD_DIR/manifest.txt" --filename with-filesystem.uf2 "$EXAMPLES_DIR"
|
$TOOLS_DIR/dir2uf2/dir2uf2 --fs-compact --sparse --append-to "$(pwd)/$BOARD.uf2" --manifest "$MICROPY_BOARD_DIR/manifest.txt" --filename with-filesystem.uf2 "$EXAMPLES_ROOT/$EXAMPLES_DIR"
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user