Skip to content
This repository was archived by the owner on Sep 16, 2024. It is now read-only.
Prev Previous commit
Next Next commit
User C modules : enable in Makefile and application.mk
  • Loading branch information
rcolistete authored and peter-pycom committed Dec 22, 2020
commit 07294854ac4b47d2af624bc868967bbbfcddf533
1 change: 1 addition & 0 deletions esp32/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,7 @@ CFLAGS_XTENSA_OPT = -Os
CFLAGS_XTENSA_PSRAM = -mfix-esp32-psram-cache-issue

CFLAGS = $(CFLAGS_XTENSA) $(CFLAGS_XTENSA_PSRAM) $(CFLAGS_XTENSA_OPT) -nostdlib -std=gnu99 -g3 -ggdb -fstrict-volatile-bitfields -Iboards/$(BOARD)
CFLAGS += $(CFLAGS_MOD) $(CFLAGS_EXTRA)
CFLAGS_SIGFOX = $(CFLAGS_XTENSA) -O2 -nostdlib -std=gnu99 -g3 -ggdb -fstrict-volatile-bitfields -Iboards/$(BOARD)

# Configure floating point support
Expand Down
6 changes: 3 additions & 3 deletions esp32/application.mk
Original file line number Diff line number Diff line change
Expand Up @@ -433,7 +433,7 @@ endif
endif # ifeq ($(OPENTHREAD), on)

OBJ += $(addprefix $(BUILD)/, $(APP_MAIN_SRC_C:.c=.o) $(APP_HAL_SRC_C:.c=.o) $(APP_LIB_SRC_C:.c=.o))
OBJ += $(addprefix $(BUILD)/, $(APP_MODS_SRC_C:.c=.o) $(APP_STM_SRC_C:.c=.o))
OBJ += $(addprefix $(BUILD)/, $(APP_MODS_SRC_C:.c=.o) $(APP_STM_SRC_C:.c=.o) $(SRC_MOD:.c=.o))
OBJ += $(addprefix $(BUILD)/, $(APP_FATFS_SRC_C:.c=.o) $(APP_LITTLEFS_SRC_C:.c=.o) $(APP_UTIL_SRC_C:.c=.o) $(APP_TELNET_SRC_C:.c=.o))
OBJ += $(addprefix $(BUILD)/, $(APP_FTP_SRC_C:.c=.o) $(APP_CAN_SRC_C:.c=.o))
ifeq ($(PYGATE_ENABLED), 1)
Expand All @@ -453,7 +453,7 @@ OBJ += $(BUILD)/pins.o
BOOT_OBJ = $(addprefix $(BUILD)/, $(BOOT_SRC_C:.c=.o))

# List of sources for qstr extraction
SRC_QSTR += $(APP_MODS_SRC_C) $(APP_UTIL_SRC_C) $(APP_STM_SRC_C) $(APP_LIB_SRC_C)
SRC_QSTR += $(APP_MODS_SRC_C) $(APP_UTIL_SRC_C) $(APP_STM_SRC_C) $(APP_LIB_SRC_C) $(SRC_MOD)
ifeq ($(BOARD), $(filter $(BOARD), LOPY LOPY4 FIPY))
SRC_QSTR += $(APP_MODS_LORA_SRC_C)
endif
Expand All @@ -480,7 +480,7 @@ BOOT_LDFLAGS = $(LDFLAGS) -T esp32.bootloader.ld -T esp32.rom.ld -T esp32.periph

# add the application linker script(s)
APP_LDFLAGS += $(LDFLAGS) -T esp32_out.ld -T esp32.project.ld -T esp32.rom.ld -T esp32.peripherals.ld -T esp32.rom.libgcc.ld -T esp32.extram.bss.ld

APP_LDFLAGS += $(LDFLAGS_MOD)
# add the application specific CFLAGS
CFLAGS += $(APP_INC) -DMICROPY_NLR_SETJMP=1 -DMBEDTLS_CONFIG_FILE='"mbedtls/esp_config.h"' -DHAVE_CONFIG_H -DESP_PLATFORM -DFFCONF_H=\"lib/oofatfs/ffconf.h\" -DWITH_POSIX
CFLAGS_SIGFOX += $(APP_INC) -DMICROPY_NLR_SETJMP=1 -DMBEDTLS_CONFIG_FILE='"mbedtls/esp_config.h"' -DHAVE_CONFIG_H -DESP_PLATFORM
Expand Down