summaryrefslogtreecommitdiffstats
path: root/resources/scripts/helpers/build/roms/withgrub_helper
diff options
context:
space:
mode:
authorFrancis Rowe <info@gluglug.org.uk>2016-03-06 19:59:00 (EST)
committer Francis Rowe <info@gluglug.org.uk>2016-03-07 02:07:45 (EST)
commit4dd16f5a28d0d799d450a49b759f28353bf5e07f (patch)
treeaedddbe5524cc960a74d9da062d57c6f45efd50c /resources/scripts/helpers/build/roms/withgrub_helper
parentb7e798ce0819a8a23c4cd4614d052e03246bba40 (diff)
downloadlibreboot-4dd16f5a28d0d799d450a49b759f28353bf5e07f.zip
libreboot-4dd16f5a28d0d799d450a49b759f28353bf5e07f.tar.gz
libreboot-4dd16f5a28d0d799d450a49b759f28353bf5e07f.tar.bz2
copy coreboot directory per revision, not per board
This will speed up the build process. The plan is to, if possible, always use 1 revision.
Diffstat (limited to 'resources/scripts/helpers/build/roms/withgrub_helper')
-rwxr-xr-xresources/scripts/helpers/build/roms/withgrub_helper32
1 files changed, 24 insertions, 8 deletions
diff --git a/resources/scripts/helpers/build/roms/withgrub_helper b/resources/scripts/helpers/build/roms/withgrub_helper
index 631b96f..047aa76 100755
--- a/resources/scripts/helpers/build/roms/withgrub_helper
+++ b/resources/scripts/helpers/build/roms/withgrub_helper
@@ -34,21 +34,31 @@ fi
boardtarget="${1}"
+if [ -f "version" ]; then
+ # release archive is being used
+ version="$(cat version)"
+else
+ # git repo is being used
+ version="$(git describe --tags HEAD)"
+fi
+
printf "GRUB Helper script: build ROM images for '%s'\n" "${boardtarget}"
(
-cd "coreboot/grub/${boardtarget}/"
+cbrevision="$(cat resources/libreboot/config/grub/${boardtarget}/cbrevision)"
+vbootrevision="$(cat resources/libreboot/config/grub/${boardtarget}/vbootrevision)"
+branchname="grub_${boardtarget}"
+
+cd "coreboot/${cbrevision}/${cbrevision}/"
+git checkout ${branchname}
+(
+ cd "3rdparty/vboot/"
+ git checkout ${branchname}
+)
# Make sure to remove these first
rm -f "grub."*{elf,cfg}
-if [ -f "../version" ]; then
- # release archive is being used
- version="$(cat ../version)"
-else
- # git repo is being used
- version="$(git describe --tags HEAD)"
-fi
printf 'libreboot-%s\n' "${version}" > ".coreboot-version" # needed for reproducible builds in coreboot
# Build ROM images with text-mode and corebootfb modes.
@@ -138,6 +148,12 @@ mv "${boardtarget}/" "../../../bin/grub/"
# version info file no longer needed
rm -f ".coreboot-version"
+
+git checkout master
+(
+ cd "3rdparty/vboot/"
+ git checkout master
+)
)
printf "\n\n"