[coreboot-gerrit] New patch to review for coreboot: Use VBOOT_SOURCE instead of hardcoding vboot path
Paul Kocialkowski (contact@paulk.fr)
gerrit at coreboot.org
Sun Jul 24 12:27:53 CEST 2016
Paul Kocialkowski (contact at paulk.fr) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/15825
-gerrit
commit b948f95db1326c710b6dbcfdd825127cd55a7574
Author: Paul Kocialkowski <contact at paulk.fr>
Date: Sun Jul 24 12:14:38 2016 +0200
Use VBOOT_SOURCE instead of hardcoding vboot path
This replaces all occurrences of a hardcoded vboot path to the
VBOOT_SOURCE variable, that may be overridden from the command line,
witch fallback to the source from 3rdparty.
Change-Id: Ia57d498d38719cc71e17060b76b0162c4ab363ed
Signed-off-by: Paul Kocialkowski <contact at paulk.fr>
---
payloads/external/depthcharge/Makefile | 7 ++++---
src/vendorcode/google/chromeos/Kconfig | 10 +++++-----
util/cbfstool/Makefile.inc | 8 +++++---
3 files changed, 14 insertions(+), 11 deletions(-)
diff --git a/payloads/external/depthcharge/Makefile b/payloads/external/depthcharge/Makefile
index cf2d0a1..edc48f8 100644
--- a/payloads/external/depthcharge/Makefile
+++ b/payloads/external/depthcharge/Makefile
@@ -8,7 +8,8 @@ project_config_file=$(project_dir)/.config
output_dir=$(project_dir)/build
libpayload_dir=$(abspath $(CURDIR)/../../libpayload)
libpayload_install_dir=$(output_dir)/lp_$(BOARD)
-vboot_dir=$(abspath $(CURDIR)/../../../3rdparty/vboot)
+
+VBOOT_SOURCE ?= $(abspath $(CURDIR)/../../../3rdparty/vboot)
TAG-$(DEPTHCHARGE_MASTER)=origin/master
TAG-$(DEPTHCHARGE_STABLE)=$(STABLE_COMMIT_ID)
@@ -55,12 +56,12 @@ config: $(libpayload_install_dir) checkout
git describe --tags --long --dirty 2>/dev/null || \
echo "unknown") ; \
cd $(project_dir) && $(MAKE) BOARD=$(BOARD) LIBPAYLOAD_DIR=$(libpayload_install_dir)/libpayload \
- VB_SOURCE=$(vboot_dir) defconfig
+ VB_SOURCE=$(VBOOT_SOURCE) defconfig
build: config
echo " MAKE $(project_name) $(TAG-y)"
cd $(project_dir) && $(MAKE) BOARD=$(BOARD) LIBPAYLOAD_DIR=$(libpayload_install_dir)/libpayload \
- VB_SOURCE=$(vboot_dir) PATH="$(abspath ../../../build/util/cbfstool):$$PATH" depthcharge_unified
+ VB_SOURCE=$(VBOOT_SOURCE) PATH="$(abspath ../../../build/util/cbfstool):$$PATH" depthcharge_unified
clean:
test -d $(output_dir) && rm -rf $(output_dir) || exit 0
diff --git a/src/vendorcode/google/chromeos/Kconfig b/src/vendorcode/google/chromeos/Kconfig
index f97a4e1..857bb63 100644
--- a/src/vendorcode/google/chromeos/Kconfig
+++ b/src/vendorcode/google/chromeos/Kconfig
@@ -249,23 +249,23 @@ endmenu # GBB
menu "Vboot Keys"
config VBOOT_ROOT_KEY
string "Root key (public)"
- default "3rdparty/vboot/tests/devkeys/root_key.vbpubk"
+ default "$(VBOOT_SOURCE)/tests/devkeys/root_key.vbpubk"
config VBOOT_RECOVERY_KEY
string "Recovery key (public)"
- default "3rdparty/vboot/tests/devkeys/recovery_key.vbpubk"
+ default "$(VBOOT_SOURCE)/tests/devkeys/recovery_key.vbpubk"
config VBOOT_FIRMWARE_PRIVKEY
string "Firmware key (private)"
- default "3rdparty/vboot/tests/devkeys/firmware_data_key.vbprivk"
+ default "$(VBOOT_SOURCE)/tests/devkeys/firmware_data_key.vbprivk"
config VBOOT_KERNEL_KEY
string "Kernel subkey (public)"
- default "3rdparty/vboot/tests/devkeys/kernel_subkey.vbpubk"
+ default "$(VBOOT_SOURCE)/tests/devkeys/kernel_subkey.vbpubk"
config VBOOT_KEYBLOCK
string "Keyblock to use for the RW regions"
- default "3rdparty/vboot/tests/devkeys/firmware.keyblock"
+ default "$(VBOOT_SOURCE)/tests/devkeys/firmware.keyblock"
config VBOOT_KEYBLOCK_VERSION
int "Keyblock version number"
diff --git a/util/cbfstool/Makefile.inc b/util/cbfstool/Makefile.inc
index 8c9a2c0..193b51a 100644
--- a/util/cbfstool/Makefile.inc
+++ b/util/cbfstool/Makefile.inc
@@ -62,6 +62,8 @@ ifwiobj :=
ifwiobj += ifwitool.o
ifwiobj += common.o
+VBOOT_SOURCE ?= $(top)/3rdparty/vboot
+
TOOLCFLAGS ?= -Werror -Wall -Wextra
TOOLCFLAGS += -Wcast-qual -Wmissing-prototypes -Wredundant-decls -Wshadow
TOOLCFLAGS += -Wstrict-prototypes -Wwrite-strings
@@ -72,8 +74,8 @@ TOOLCPPFLAGS += -I$(top)/util/cbfstool
TOOLCPPFLAGS += -I$(objutil)/cbfstool
TOOLCPPFLAGS += -I$(top)/src/commonlib/include
TOOLCPPFLAGS += -DNEED_VB2_SHA_LIBRARY
-TOOLCPPFLAGS += -I$(top)/3rdparty/vboot/firmware/include
-TOOLCPPFLAGS += -I$(top)/3rdparty/vboot/firmware/2lib/include
+TOOLCPPFLAGS += -I$(VBOOT_SOURCE)/firmware/include
+TOOLCPPFLAGS += -I$(VBOOT_SOURCE)/firmware/2lib/include
# UEFI header file support. It's not pretty, but that's what we currently
# have right now.
TOOLCPPFLAGS += -I$(top)/src
@@ -112,7 +114,7 @@ $(objutil)/cbfstool/%.o: $(top)/util/cbfstool/lzma/C/%.c
printf " HOSTCC $(subst $(objutil)/,,$(@))\n"
$(HOSTCC) $(TOOLCPPFLAGS) $(TOOLCFLAGS) $(HOSTCFLAGS) -c -o $@ $<
-$(objutil)/cbfstool/%.o: $(top)/3rdparty/vboot/firmware/2lib/%.c
+$(objutil)/cbfstool/%.o: $(VBOOT_SOURCE)/firmware/2lib/%.c
printf " HOSTCC $(subst $(objutil)/,,$(@))\n"
$(HOSTCC) $(TOOLCPPFLAGS) $(TOOLCFLAGS) $(HOSTCFLAGS) -c -o $@ $<
More information about the coreboot-gerrit
mailing list