mirror of
https://codeberg.org/libreboot/lbmk.git
synced 2026-07-14 23:39:33 +02:00
build/boot/roms: don't use subshells frivilously
use make -BC instead of cd
This commit is contained in:
@@ -386,10 +386,7 @@ build_rom_images()
|
|||||||
done
|
done
|
||||||
done
|
done
|
||||||
|
|
||||||
(
|
make distclean -BC "${cbdir}"
|
||||||
cd "${cbdir}"
|
|
||||||
make distclean # TODO: do make clean instead (avoid re-building utils)
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# Main ROM building function. This calls all other functions
|
# Main ROM building function. This calls all other functions
|
||||||
@@ -481,26 +478,19 @@ mkCoreboot()
|
|||||||
printf "%s-%s\n" "$(cat projectname)" "$(cat version)" \
|
printf "%s-%s\n" "$(cat projectname)" "$(cat version)" \
|
||||||
> "${cbdir}/.coreboot-version"
|
> "${cbdir}/.coreboot-version"
|
||||||
|
|
||||||
(
|
|
||||||
if [ -f "${cbfstool}" ]; then
|
if [ -f "${cbfstool}" ]; then
|
||||||
mv "${cbfstool}" "${cbdir}/cbfstool"
|
mv "${cbfstool}" "${cbdir}/cbfstool"
|
||||||
fi
|
fi
|
||||||
cd "${cbdir}"
|
make clean -BC "${cbdir}"
|
||||||
make distclean
|
|
||||||
cd -
|
|
||||||
|
|
||||||
if [ -f "${cbdir}/cbfstool" ]; then
|
if [ -f "${cbdir}/cbfstool" ]; then
|
||||||
mv "${cbdir}/cbfstool" "${cbfstool}"
|
mv "${cbdir}/cbfstool" "${cbfstool}"
|
||||||
fi
|
fi
|
||||||
)
|
|
||||||
|
|
||||||
cp "${_cbcfg}" "${cbdir}"/.config
|
cp "${_cbcfg}" "${cbdir}"/.config
|
||||||
./build module cbutils ${cbdir#coreboot/} || exit 1
|
./build module cbutils ${cbdir#coreboot/} || exit 1
|
||||||
|
|
||||||
(
|
make -j$(nproc) -BC "${cbdir}"
|
||||||
cd "${cbdir}"
|
|
||||||
make -j$(nproc)
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# make a rom in /tmp/ and then print the path of that ROM
|
# make a rom in /tmp/ and then print the path of that ROM
|
||||||
|
|||||||
Reference in New Issue
Block a user