Attention is currently required from: Arthur Heymans. Hello Arthur Heymans,
I'd like you to do a code review. Please visit
https://review.coreboot.org/c/coreboot/+/63084
to review the following change.
Change subject: [WIP]abuild: Build with clang only when supported ......................................................................
[WIP]abuild: Build with clang only when supported
Change-Id: I362fcd0f795d27f13dde793a79774f08c497bd38 Signed-off-by: Arthur Heymans arthur@aheymans.xyz --- M util/abuild/abuild 1 file changed, 11 insertions(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/84/63084/1
diff --git a/util/abuild/abuild b/util/abuild/abuild index cc149a8..2585b57 100755 --- a/util/abuild/abuild +++ b/util/abuild/abuild @@ -456,6 +456,14 @@ local FORCE_ENABLED_CROS=0 fi
+ if [ "$clang" = true ]; then + check_config "$build_dir" "clang" "CONFIG_COMPILER_LLVM_CLANG=y" + if [ $? -ne 0 ]; then + echo "${MAINBOARD} doesn't support Clang, skipping." + return + fi + fi + if [ $BUILDENV_CREATED -ne 0 ] || [ $MAINBOARD_OK -ne 0 ] || [ $VENDOR_OK -ne 0 ] || [ $FORCE_ENABLED_CROS -eq 1 ]; then junit " <testcase classname='board${testclass/#/.}' name='$BUILD_NAME' >"
@@ -587,7 +595,7 @@ [-J|--junit] Write JUnit formatted xml log file [-K|--kconfig <name>] Prepend file to generated Kconfig [-l|--loglevel <num>] Set loglevel - [-L|--clang] Use clang + [-L|--clang] Use clang on supported arch [-o|--outdir <path>] Store build results in path (defaults to $TARGET) [-p|--payloads <dir>] Use payloads in <dir> to build images @@ -671,6 +679,7 @@ fi
chromeos=false +clang=false clean_work=false clean_objs=false verboseopt='V=0' @@ -738,6 +747,7 @@ configoptions="${configoptions}CONFIG_ANY_TOOLCHAIN=y\n" ;; -L|--clang) shift + clang=true customizing="${customizing}, clang" configoptions="${configoptions}CONFIG_COMPILER_LLVM_CLANG=y\n# CONFIG_COMPILER_GCC is not set\n" ;;