aboutsummaryrefslogtreecommitdiff
path: root/extmod
diff options
context:
space:
mode:
Diffstat (limited to 'extmod')
-rw-r--r--extmod/extmod.mk15
1 files changed, 14 insertions, 1 deletions
diff --git a/extmod/extmod.mk b/extmod/extmod.mk
index e714b6028..69d8cfad3 100644
--- a/extmod/extmod.mk
+++ b/extmod/extmod.mk
@@ -1,7 +1,20 @@
# This makefile fragment provides rules to build 3rd-party components for extmod modules
+################################################################################
+# VFS FAT FS
+
+OOFATFS_DIR = lib/oofatfs
+
# this sets the config file for FatFs
-CFLAGS_MOD += -DFFCONF_H=\"lib/oofatfs/ffconf.h\"
+CFLAGS_MOD += -DFFCONF_H=\"$(OOFATFS_DIR)/ffconf.h\"
+
+ifeq ($(MICROPY_VFS_FAT),1)
+CFLAGS_MOD += -DMICROPY_VFS_FAT=1
+SRC_MOD += $(addprefix $(OOFATFS_DIR)/,\
+ ff.c \
+ ffunicode.c \
+ )
+endif
################################################################################
# VFS littlefs