blobutil/download: move Build_deps to the top

It's called first, so declare it first!
fsdg20230625
Leah Rowe 2023-04-01 11:13:04 +01:00
parent 7f3c0ca81e
commit 14b5947ed9
1 changed files with 17 additions and 17 deletions

View File

@ -13,6 +13,23 @@ Fail(){
exit 1
}
Build_deps(){
if [ ! -d me_cleaner ]; then
printf "downloading me_cleaner\n"
./download me_cleaner || Fail 'could not download me_cleaner'
fi
if [ ! -d coreboot/default ]; then
printf "downloading coreboot\n"
./download coreboot default || Fail 'could not download coreboot'
fi
if [ ! -f "coreboot/default/util/ifdtool/ifdtool" ]; then
printf "building ifdtool from coreboot\n"
make -C coreboot/default/util/ifdtool || Fail 'could not build ifdtool'
fi
}
Download_needed(){
for need in ${needs}; do
case ${need} in
@ -74,23 +91,6 @@ Extract_me(){
printf "Truncated and cleaned me output to ${_me_destination}\n"
}
Build_deps(){
if [ ! -d me_cleaner ]; then
printf "downloading me_cleaner\n"
./download me_cleaner || Fail 'could not download me_cleaner'
fi
if [ ! -d coreboot/default ]; then
printf "downloading coreboot\n"
./download coreboot default || Fail 'could not download coreboot'
fi
if [ ! -f "coreboot/default/util/ifdtool/ifdtool" ]; then
printf "building ifdtool from coreboot\n"
make -C coreboot/default/util/ifdtool || Fail 'could not build ifdtool'
fi
}
set -- "resources/coreboot/${board}/config/*"
. ${1} 2>/dev/null
. "resources/coreboot/${board}/board.cfg"