mirror of
https://codeberg.org/libreboot/lbmk.git
synced 2026-07-15 08:20:59 +02:00
general code cleanup on lbmk shell scripts
in update/blobs/download, i saw instances where appdir was being deleted with rm -r, but the more appropriate command would rm -Rf. this is now fixed. other than that, i've mostly just simplified a bunch of if statements and consolidated some duplicated logic (e.g. if/else block for dependencies in build_dependencies() of update/blobs/download one or two functions and/or variables have been renamed, for greater clarity in the code, also removed a few messages that were redundant used printf instead of echo, in a few places, also fixed up the indentation in a few places Signed-off-by: Leah Rowe <leah@libreboot.org>
This commit is contained in:
@@ -25,11 +25,7 @@ set -u -e
|
||||
main()
|
||||
{
|
||||
printf "Building GRUB\n"
|
||||
|
||||
if [ ! -d "grub/" ]; then
|
||||
./fetch grub || exit 1
|
||||
fi
|
||||
|
||||
[ -d "grub/" ] || ./fetch grub || exit 1
|
||||
build_grub
|
||||
}
|
||||
|
||||
@@ -37,15 +33,8 @@ build_grub()
|
||||
{
|
||||
(
|
||||
cd grub/ || err "cd"
|
||||
|
||||
# clean up first
|
||||
if [ -d Makefile ]; then
|
||||
make distclean || err "make-distclean"
|
||||
fi
|
||||
|
||||
[ ! -d Makefile ] || make distclean || err "make-distclean"
|
||||
./bootstrap --gnulib-srcdir=gnulib/ --no-git || err "bootstrap"
|
||||
|
||||
# build
|
||||
./autogen.sh || err "autogen"
|
||||
./configure --with-platform=coreboot || err "configure"
|
||||
make -j$(nproc) || err "make"
|
||||
|
||||
Reference in New Issue
Block a user