summaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
Diffstat (limited to 'util')
-rw-r--r--util/cbfstool/Makefile2
-rw-r--r--util/cbfstool/Makefile.inc6
2 files changed, 5 insertions, 3 deletions
diff --git a/util/cbfstool/Makefile b/util/cbfstool/Makefile
index 320485749b..d6249bc24e 100644
--- a/util/cbfstool/Makefile
+++ b/util/cbfstool/Makefile
@@ -6,6 +6,8 @@ CONFIG_FMD_GENPARSER ?= n
HOSTCC ?= $(CC)
OBJCOPY ?= objcopy
+VBOOT_SOURCE ?= $(top)/3rdparty/vboot
+
.PHONY: all
all: cbfstool fmaptool rmodtool ifwitool
diff --git a/util/cbfstool/Makefile.inc b/util/cbfstool/Makefile.inc
index 8c9a2c01bd..d666f6a06f 100644
--- a/util/cbfstool/Makefile.inc
+++ b/util/cbfstool/Makefile.inc
@@ -72,8 +72,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 +112,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 $@ $<