Nico Huber submitted this change.

View Change

Approvals: build bot (Jenkins): Verified Nico Huber: Looks good to me, approved Felix Singer: Looks good to me, but someone else must approve Angel Pons: Looks good to me, but someone else must approve
Makefile: use the HAS_ USE_ scheme for linux i2c dependent programmer

Change-Id: I47acdf89a369441b9fc664352c27c43b461545b1
Signed-off-by: Thomas Heijligen <thomas.heijligen@secunet.com>
Reviewed-on: https://review.coreboot.org/c/flashrom/+/62197
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Felix Singer <felixsinger@posteo.net>
---
M Makefile
1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/Makefile b/Makefile
index 9a9628f..a2ba3b0 100644
--- a/Makefile
+++ b/Makefile
@@ -168,6 +168,10 @@
DEPENDS_ON_LIB_NI845X := \
CONFIG_NI845X_SPI \

+DEPENDS_ON_LINUX_I2C := \
+ CONFIG_MSTARDDC_SPI \
+ CONFIG_LSPCON_I2C_SPI \
+ CONFIG_REALTEK_MST_I2C_SPI \

ifeq ($(CONFIG_ENABLE_LIBUSB1_PROGRAMMERS), no)
$(call disable_all,$(DEPENDS_ON_LIBUSB1))
@@ -302,7 +306,7 @@
endif

ifeq ($(HAS_LINUX_I2C), no)
-$(call mark_unsupported,CONFIG_MSTARDDC_SPI CONFIG_LSPCON_I2C_SPI CONFIG_REALTEK_MST_I2C_SPI)
+$(call mark_unsupported,DEPENDS_ON_LINUX_I2C)
endif

ifeq ($(TARGET_OS), Android)
@@ -800,7 +804,8 @@
PROGRAMMER_OBJS += ni845x_spi.o
endif

-ifeq ($(HAS_LINUX_I2C), yes)
+USE_LINUX_I2C := $(if $(call filter_deps,$(DEPENDS_ON_LINUX_I2C)),yes,no)
+ifeq ($(USE_LINUX_I2C), yes)
LIB_OBJS += i2c_helper_linux.o
endif


2 is the latest approved patch-set. No files were changed between the latest approved patch-set and the submitted one.

To view, visit change 62197. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: I47acdf89a369441b9fc664352c27c43b461545b1
Gerrit-Change-Number: 62197
Gerrit-PatchSet: 6
Gerrit-Owner: Thomas Heijligen <src@posteo.de>
Gerrit-Reviewer: Angel Pons <th3fanbus@gmail.com>
Gerrit-Reviewer: Felix Singer <felixsinger@posteo.net>
Gerrit-Reviewer: Nico Huber <nico.h@gmx.de>
Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org>
Gerrit-CC: Edward O'Callaghan <quasisec@chromium.org>
Gerrit-CC: Paul Menzel <paulepanter@mailbox.org>
Gerrit-MessageType: merged