Skip to content

Commit 559eb7c

Browse files
VynDragondpgeorge
authored andcommitted
zephyr/CMakeLists.txt: Fix FS config options being ignored.
This makes CONFIG_MICROPY_VFS_* actually do things. Signed-off-by: Vdragon <mail@massdriver.space>
1 parent e743676 commit 559eb7c

File tree

1 file changed

+20
-1
lines changed

1 file changed

+20
-1
lines changed

ports/zephyr/CMakeLists.txt

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,14 +82,33 @@ set(MICROPY_QSTRDEFS_PORT
8282
${MICROPY_PORT_DIR}/qstrdefsport.h
8383
)
8484

85-
set(MICROPY_SOURCE_LIB
85+
if (CONFIG_MICROPY_VFS_FAT)
86+
87+
list(APPEND MICROPY_SOURCE_LIB
8688
oofatfs/ff.c
8789
oofatfs/ffunicode.c
90+
)
91+
92+
endif()
93+
94+
if (CONFIG_MICROPY_VFS_LFS1)
95+
96+
list(APPEND MICROPY_SOURCE_LIB
8897
littlefs/lfs1.c
8998
littlefs/lfs1_util.c
99+
)
100+
101+
endif()
102+
103+
if (CONFIG_MICROPY_VFS_LFS2)
104+
105+
list(APPEND MICROPY_SOURCE_LIB
90106
littlefs/lfs2.c
91107
littlefs/lfs2_util.c
92108
)
109+
110+
endif()
111+
93112
list(TRANSFORM MICROPY_SOURCE_LIB PREPEND ${MICROPY_DIR}/lib/)
94113

95114
set(MICROPY_SOURCE_QSTR

0 commit comments

Comments
 (0)