From ce08f23b066bc29d64bad2c7b5f18a470044b8d7 Mon Sep 17 00:00:00 2001 From: Lup Yuen Lee Date: Tue, 15 Oct 2024 16:05:55 +0800 Subject: [PATCH] Update --- .github/workflows/build.yml | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index de802ef83f79a..ddac491d9bc47 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -181,6 +181,35 @@ jobs: export ARTIFACTDIR=`pwd`/buildartifacts git config --global --add safe.directory /github/workspace/sources/nuttx git config --global --add safe.directory /github/workspace/sources/apps + + # Validate the defconfig files + pushd sources/nuttx + testfile=tools/ci/testlist/${{matrix.boards}}.dat + echo Validating targets in $testfile + testlist=`grep -v -E "^(-|#)|^[C|c][M|m][A|a][K|k][E|e]" $testfile || true` + for line in $testlist; do + firstch=${line:0:1} + if [ "X$firstch" == "X/" ]; then + dir=`echo $line | cut -d',' -f1` + list=`find boards$dir -name defconfig | cut -d'/' -f4,6` + for config in ${list}; do + echo ./tools/refresh.sh --silent $config + if ! ./tools/refresh.sh --silent $config; then + echo ERROR: $config is configured incorrectly + fail=1 + fi + done + fi + done + popd + + # Quit if the defconfig validation failed + if [[ "$fail" == "1" ]]; then + echo Quitting, defconfig validation failed for $testfile + exit 1 + fi + + # Build the targets cd sources/nuttx/tools/ci if [ "X${{matrix.boards}}" = "Xcodechecker" ]; then ./cibuild.sh -c -A -N -R --codechecker testlist/${{matrix.boards}}.dat