From e7d598ba2c15f2c4ca98100ffc81464efdfef042 Mon Sep 17 00:00:00 2001 From: "roccochen@chromium.com" Date: Thu, 2 Nov 2023 15:49:02 +0800 Subject: [PATCH] Reland "tests: Allow specifying vboot source directory" Respect VBOOT_SOURCE while including generic headers. This reverts commit 26e7c1eae4120b0d7212d28f6dfa25f14484d319. BUG=none TEST=make clean-unit-tests && VBOOT_SOURCE=/path/to/vboot_reference/ make unit-tests -j TEST=make clean-unit-tests && make unit-tests -j BRANCH=none Change-Id: I686575f7c5e22bee519e910f71a4ac579b5c6a50 Signed-off-by: Hsuan Ting Chen Signed-off-by: Yu-Ping Wu Reviewed-on: https://review.coreboot.org/c/coreboot/+/89176 Tested-by: build bot (Jenkins) Reviewed-by: Hsuan-ting Chen --- Makefile | 1 + Makefile.mk | 1 - tests/Makefile.common | 2 +- 3 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 24b7c9624b..7c63040790 100644 --- a/Makefile +++ b/Makefile @@ -15,6 +15,7 @@ absobj := $(abspath $(obj)) additional-dirs := +VBOOT_SOURCE ?= 3rdparty/vboot VBOOT_HOST_BUILD ?= $(abspath $(objutil)/vboot_lib) COREBOOT_EXPORTS := COREBOOT_EXPORTS diff --git a/Makefile.mk b/Makefile.mk index 218e388bb5..1c5b8f05d5 100644 --- a/Makefile.mk +++ b/Makefile.mk @@ -484,7 +484,6 @@ CPPFLAGS_common += -Isrc/include CPPFLAGS_common += -Isrc/commonlib/include CPPFLAGS_common += -Isrc/commonlib/bsd/include CPPFLAGS_common += -I$(obj) -VBOOT_SOURCE ?= 3rdparty/vboot CPPFLAGS_common += -I$(VBOOT_SOURCE)/firmware/include CPPFLAGS_common += -include $(src)/include/kconfig.h CPPFLAGS_common += -include $(src)/include/rules.h diff --git a/tests/Makefile.common b/tests/Makefile.common index dd7cca29f4..74a3c5a7a9 100644 --- a/tests/Makefile.common +++ b/tests/Makefile.common @@ -36,7 +36,7 @@ TEST_INCLUDES += -I$(testsrc)/include/mocks -I$(testsrc)/include TEST_INCLUDES += -I$(src) -I$(src)/include -I$(src)/commonlib/include \ -I$(src)/commonlib/bsd/include -I$(src)/arch/x86/include \ - -I$(top)/3rdparty/vboot/firmware/include + -I$(abspath $(VBOOT_SOURCE))/firmware/include # Path for Kconfig autoheader TEST_INCLUDES += -I$(dir $(TEST_KCONFIG_AUTOHEADER))