From ba36f26d6266ef6f980ddd9db5237db29d1c7c66 Mon Sep 17 00:00:00 2001 From: Leah Rowe Date: Thu, 6 Jun 2024 02:35:36 +0100 Subject: handle build.list from config/data/, not config/ certain code checks for build.list, to skip it, for example in items() we already use config/data/grub to store grub config data that applied to all trees create these directories too: config/data/coreboot config/data/u-boot config/data/seabios move the respective build.list files in here, and also to config/data/grub now multi-tree projects contain, per directory, just the target.cfg file and the patches directory. this is much cleaner, because some of the logic can be simplified more Signed-off-by: Leah Rowe --- config/coreboot/build.list | 1 - config/data/coreboot/build.list | 1 + config/data/grub/build.list | 1 + config/data/seabios/build.list | 2 ++ config/data/u-boot/build.list | 6 ++++++ config/grub/build.list | 1 - config/seabios/build.list | 2 -- config/u-boot/build.list | 6 ------ include/lib.sh | 1 - script/trees | 5 +++-- 10 files changed, 13 insertions(+), 13 deletions(-) delete mode 100644 config/coreboot/build.list create mode 100644 config/data/coreboot/build.list create mode 100644 config/data/grub/build.list create mode 100644 config/data/seabios/build.list create mode 100644 config/data/u-boot/build.list delete mode 100644 config/grub/build.list delete mode 100644 config/seabios/build.list delete mode 100644 config/u-boot/build.list diff --git a/config/coreboot/build.list b/config/coreboot/build.list deleted file mode 100644 index f6535149..00000000 --- a/config/coreboot/build.list +++ /dev/null @@ -1 +0,0 @@ -build/coreboot.rom diff --git a/config/data/coreboot/build.list b/config/data/coreboot/build.list new file mode 100644 index 00000000..f6535149 --- /dev/null +++ b/config/data/coreboot/build.list @@ -0,0 +1 @@ +build/coreboot.rom diff --git a/config/data/grub/build.list b/config/data/grub/build.list new file mode 100644 index 00000000..5b891e5a --- /dev/null +++ b/config/data/grub/build.list @@ -0,0 +1 @@ +grub.elf diff --git a/config/data/seabios/build.list b/config/data/seabios/build.list new file mode 100644 index 00000000..d6fefb4e --- /dev/null +++ b/config/data/seabios/build.list @@ -0,0 +1,2 @@ +out/bios.bin.elf +out/vgabios.bin diff --git a/config/data/u-boot/build.list b/config/data/u-boot/build.list new file mode 100644 index 00000000..8d9a5cf0 --- /dev/null +++ b/config/data/u-boot/build.list @@ -0,0 +1,6 @@ +u-boot +u-boot.bin +u-boot.dtb +u-boot.img +u-boot.itb +u-boot.elf diff --git a/config/grub/build.list b/config/grub/build.list deleted file mode 100644 index 5b891e5a..00000000 --- a/config/grub/build.list +++ /dev/null @@ -1 +0,0 @@ -grub.elf diff --git a/config/seabios/build.list b/config/seabios/build.list deleted file mode 100644 index d6fefb4e..00000000 --- a/config/seabios/build.list +++ /dev/null @@ -1,2 +0,0 @@ -out/bios.bin.elf -out/vgabios.bin diff --git a/config/u-boot/build.list b/config/u-boot/build.list deleted file mode 100644 index 8d9a5cf0..00000000 --- a/config/u-boot/build.list +++ /dev/null @@ -1,6 +0,0 @@ -u-boot -u-boot.bin -u-boot.dtb -u-boot.img -u-boot.itb -u-boot.elf diff --git a/include/lib.sh b/include/lib.sh index bc2232ad..3ef3e3fe 100755 --- a/include/lib.sh +++ b/include/lib.sh @@ -122,7 +122,6 @@ items() for x in "$1/"*; do # -e used because this is for files *or* directories [ -e "$x" ] || continue - [ "${x##*/}" = "build.list" ] && continue printf "%s\n" "${x##*/}" 2>/dev/null rval=0 done diff --git a/script/trees b/script/trees index 897c6ed3..d681a870 100755 --- a/script/trees +++ b/script/trees @@ -11,7 +11,7 @@ set -u -e eval "$(setvars "" xarch cfgsdir cdir config config_name xlang mode makeargs \ listfile project target target_dir targets tree _f target1 bootstrapargs \ - autoconfargs cmakedir elfdir autogenargs xtree)" + autoconfargs cmakedir elfdir autogenargs xtree datadir)" main() { @@ -34,6 +34,7 @@ main() [ -z "$_f" ] && $err "missing flag (-m/-u/-b/-c/-x/-f/-s/-l/-n)" [ -z "$project" ] && $err "project name not specified" elfdir="elf/$project" + datadir="config/data/$project" cfgsdir="config/$project" remkdir "${tmpgit%/*}" @@ -66,7 +67,7 @@ build_targets() [ -d "$cfgsdir" ] || $err "directory, $cfgsdir, does not exist" - listfile="$cfgsdir/build.list" + listfile="$datadir/build.list" [ -f "$listfile" ] || $err "list file, $listfile, does not exist" # Build for all targets if no argument is given -- cgit v1.2.1