diff options
-rwxr-xr-x | include/lib.sh | 16 | ||||
-rwxr-xr-x | script/trees | 18 |
2 files changed, 17 insertions, 17 deletions
diff --git a/include/lib.sh b/include/lib.sh index eed75e2a..4ae4ad5b 100755 --- a/include/lib.sh +++ b/include/lib.sh @@ -154,22 +154,6 @@ check_defconfig() done } -handle_coreboot_utils() -{ - for util in cbfstool ifdtool; do - utilelfdir="elf/$util/$1" - utilsrcdir="src/coreboot/$1/util/$util" - - utilmode="" - [ -z "$mode" ] || utilmode="clean" - x_ make -C "$utilsrcdir" $utilmode - [ -z "$mode" ] && [ ! -f "$utilelfdir/$util" ] && \ - x_ mkdir -p "$utilelfdir" && \ - x_ cp "$utilsrcdir/$util" "elf/$util/$1" - [ -z "$mode" ] || x_ rm -Rf "$utilelfdir" - done -} - remkdir() { rm -Rf "$1" || $err "remkdir: !rm -Rf \"$1\"" diff --git a/script/trees b/script/trees index c806b92a..36cf48e4 100755 --- a/script/trees +++ b/script/trees @@ -105,7 +105,7 @@ handle_defconfig() handle_src_tree "$target" || return 0 [ "$target1" = "utils" ] && [ "$project" = "coreboot" ] && \ - eval "handle_coreboot_utils \"$tree\"; return 0" + eval "check_coreboot_utils \"$tree\"; return 0" for y in "$target_dir/config"/*; do [ -f "$y" ] || continue @@ -171,6 +171,22 @@ check_cross_compiler() done } +check_coreboot_utils() +{ + for util in cbfstool ifdtool; do + utilelfdir="elf/$util/$1" + utilsrcdir="src/coreboot/$1/util/$util" + + utilmode="" + [ -z "$mode" ] || utilmode="clean" + x_ make -C "$utilsrcdir" $utilmode + [ -z "$mode" ] && [ ! -f "$utilelfdir/$util" ] && \ + x_ mkdir -p "$utilelfdir" && \ + x_ cp "$utilsrcdir/$util" "elf/$util/$1" + [ -z "$mode" ] || x_ rm -Rf "$utilelfdir" + done +} + check_config() { [ -f "$config" ] || $err "check_config $project/$target: no config" |