esp-idf/components/esp_hw_support/Makefile.projbuild

20 lines
684 B
Makefile
Raw Normal View History

2021-03-19 03:54:30 -04:00
# Enable psram cache bug workaround in compiler if selected
ifdef CONFIG_SPIRAM_CACHE_WORKAROUND
SPIRAM_CACHE_WORKAROUND_FLAGS = -mfix-esp32-psram-cache-issue
ifdef CONFIG_SPIRAM_CACHE_WORKAROUND_STRATEGY_DUPLDST
SPIRAM_CACHE_WORKAROUND_FLAGS += -mfix-esp32-psram-cache-strategy=dupldst
endif
ifdef CONFIG_SPIRAM_CACHE_WORKAROUND_STRATEGY_MEMW
SPIRAM_CACHE_WORKAROUND_FLAGS += -mfix-esp32-psram-cache-strategy=memw
endif
ifdef CONFIG_SPIRAM_CACHE_WORKAROUND_STRATEGY_NOPS
SPIRAM_CACHE_WORKAROUND_FLAGS += -mfix-esp32-psram-cache-strategy=nops
endif
CFLAGS+=$(SPIRAM_CACHE_WORKAROUND_FLAGS)
CXXFLAGS+=$(SPIRAM_CACHE_WORKAROUND_FLAGS)
LDFLAGS+=$(SPIRAM_CACHE_WORKAROUND_FLAGS)
endif