[conf] only error on unconfigured x_I2C_DEV if TARGET is ap

This commit is contained in:
Felix Ruess
2013-10-12 01:03:08 +02:00
parent ede94e0375
commit d3768649e3
2 changed files with 4 additions and 0 deletions
@@ -59,9 +59,11 @@ else ifeq ($(ARCH), stm32)
DROTEK_2_I2C_DEV ?= i2c2
endif
ifeq ($(TARGET), ap)
ifndef DROTEK_2_I2C_DEV
$(error Error: DROTEK_2_I2C_DEV not configured!)
endif
endif
# convert i2cx to upper/lower case
DROTEK_2_I2C_DEV_UPPER=$(shell echo $(DROTEK_2_I2C_DEV) | tr a-z A-Z)
@@ -28,9 +28,11 @@ else ifeq ($(ARCH), stm32)
GL1_I2C_DEV ?= i2c2
endif
ifeq ($(TARGET), ap)
ifndef GL1_I2C_DEV
$(error Error: GL1_I2C_DEV not configured!)
endif
endif
# convert i2cx to upper/lower case
GL1_I2C_DEV_UPPER=$(shell echo $(GL1_I2C_DEV) | tr a-z A-Z)