RIOT/sys/arduino/Makefile.include
Alexandre Abadie 56e1b96a30
initial commit
2022-02-08 11:30:49 +01:00

25 lines
765 B
Makefile

# Add Arduino sketches to the application as a module
SKETCHES = $(wildcard $(APPDIR)/*.sketch)
SKETCH_MODULE = arduino_sketches
ifneq (,$(SKETCHES))
# Define application sketches module, it will be generated into $(BINDIR)
SKETCH_MODULE_DIR ?= $(BINDIR)/$(SKETCH_MODULE)
include $(RIOTBASE)/sys/arduino/sketches.inc.mk
# Depends on module
DIRS += $(SKETCH_MODULE_DIR)
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
# include the Arduino headers
INCLUDES += -I$(RIOTBASE)/sys/arduino/include
PSEUDOMODULES += arduino_pwm
PSEUDOMODULES += arduino_serial_stdio