sys/arduino: include arduino_sketches in Makefile.dep

This commit is contained in:
Francisco Molina 2020-06-25 09:34:11 +02:00
parent 9909cdfffd
commit e7a8c58de4
No known key found for this signature in database
GPG Key ID: 3E94EAC3DBDEEDA8
2 changed files with 6 additions and 2 deletions

View File

@ -2,6 +2,8 @@ ifneq (,$(filter arduino,$(USEMODULE)))
FEATURES_OPTIONAL += periph_i2c FEATURES_OPTIONAL += periph_i2c
FEATURES_OPTIONAL += periph_spi FEATURES_OPTIONAL += periph_spi
FEATURES_REQUIRED += periph_uart FEATURES_REQUIRED += periph_uart
SKETCH_MODULE ?= arduino_sketches
USEMODULE += $(SKETCH_MODULE)
endif endif
ifneq (,$(filter eepreg,$(USEMODULE))) ifneq (,$(filter eepreg,$(USEMODULE)))

View File

@ -4,14 +4,16 @@ SKETCHES = $(wildcard $(APPDIR)/*.sketch)
ifneq (,$(SKETCHES)) ifneq (,$(SKETCHES))
# Define application sketches module, it will be generated into $(BINDIR) # Define application sketches module, it will be generated into $(BINDIR)
SKETCH_MODULE ?= arduino_sketches
SKETCH_MODULE_DIR ?= $(BINDIR)/$(SKETCH_MODULE) SKETCH_MODULE_DIR ?= $(BINDIR)/$(SKETCH_MODULE)
include $(RIOTBASE)/sys/arduino/sketches.inc.mk include $(RIOTBASE)/sys/arduino/sketches.inc.mk
# Depends on module # Depends on module
USEMODULE += $(SKETCH_MODULE)
DIRS += $(SKETCH_MODULE_DIR) DIRS += $(SKETCH_MODULE_DIR)
BUILDDEPS += $(SKETCH_GENERATED_FILES) BUILDDEPS += $(SKETCH_GENERATED_FILES)
else
# arduino_sketches is now always included if arduino is, but if there
# are no sketches then no %.a will be present, so declare PSEUDOMODULE
PSEUDOMODULES += $(SKETCH_MODULE)
endif endif
# include the Arduino headers # include the Arduino headers