zephyr/CMakeLists.txt: Fix FS config options being ignored.

This makes CONFIG_MICROPY_VFS_* actually do things.

Signed-off-by: Vdragon <mail@massdriver.space>
This commit is contained in:
Vdragon
2025-10-01 15:00:18 +02:00
committed by Damien George
parent e74367684e
commit 559eb7cdb3

View File

@@ -82,14 +82,33 @@ set(MICROPY_QSTRDEFS_PORT
${MICROPY_PORT_DIR}/qstrdefsport.h
)
set(MICROPY_SOURCE_LIB
if (CONFIG_MICROPY_VFS_FAT)
list(APPEND MICROPY_SOURCE_LIB
oofatfs/ff.c
oofatfs/ffunicode.c
)
endif()
if (CONFIG_MICROPY_VFS_LFS1)
list(APPEND MICROPY_SOURCE_LIB
littlefs/lfs1.c
littlefs/lfs1_util.c
)
endif()
if (CONFIG_MICROPY_VFS_LFS2)
list(APPEND MICROPY_SOURCE_LIB
littlefs/lfs2.c
littlefs/lfs2_util.c
)
endif()
list(TRANSFORM MICROPY_SOURCE_LIB PREPEND ${MICROPY_DIR}/lib/)
set(MICROPY_SOURCE_QSTR