Skip to content

Commit

Permalink
make: Guard inclusion of the Puya family micros to mitigate the Flash…
Browse files Browse the repository at this point in the history
… usage problem on native
  • Loading branch information
dragonmux committed May 12, 2024
1 parent 148169b commit 8be1fcf
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ VPATH += $(PLATFORM_DIR) target
ENABLE_DEBUG ?= 0
ENABLE_CORTEXAR ?= 0
ENABLE_RISCV ?= 0
ENABLE_PUYA ?= 0
ENABLE_XILINX ?= 0

SYS = $(shell $(CC) -dumpmachine)
Expand Down Expand Up @@ -71,7 +72,6 @@ SRC = \
nrf51.c \
nrf91.c \
nxpke04.c \
puya.c \
remote.c \
rp.c \
sam3x.c \
Expand Down Expand Up @@ -100,6 +100,11 @@ ifeq (,$(filter all_platforms,$(MAKECMDGOALS)))
include $(PLATFORM_DIR)/Makefile.inc
endif

ifeq ($(ENABLE_PUYA), 1)
SRC += \
puya.c
endif

ifeq ($(ENABLE_CORTEXAR), 1)
CFLAGS += -DENABLE_CORTEXAR
SRC += \
Expand Down
1 change: 1 addition & 0 deletions src/platforms/hosted/Makefile.inc
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ CFLAGS +=-I ./target
ENABLE_CORTEXAR := 1
ENABLE_RISCV := 1
# Target enables
ENABLE_PUYA := 1
ENABLE_XILINX := 1

# Clang requires some special handling here: -gnu means MinGW
Expand Down

0 comments on commit 8be1fcf

Please sign in to comment.