rp2: Allow using btree module with rp2 port #1

Merged
matthias merged 1 commits from v1.25-tonberry-enable-btree into v1.25-tonberry 2025-08-19 18:05:44 +00:00

View File

@@ -474,6 +474,15 @@ if (MICROPY_PY_NETWORK_WIZNET5K)
)
endif()
if (MICROPY_PY_BTREE)
target_link_libraries(${MICROPY_TARGET} micropy_extmod_btree)
target_compile_definitions(${MICROPY_TARGET} PRIVATE
MICROPY_STREAMS_POSIX_API=1
MICROPY_BERKELEY_DB_DEFPSIZE=1024
MICROPY_BERKELEY_DB_MINCACHE=3
)
endif()
# Add qstr sources for extmod and usermod, in case they are modified by components above.
list(APPEND MICROPY_SOURCE_QSTR
${MICROPY_SOURCE_EXTMOD}
@@ -554,6 +563,7 @@ set_source_files_properties(
)
target_compile_definitions(${MICROPY_TARGET} PRIVATE
${MICROPY_DEF_CORE}
${MICROPY_DEF_BOARD}
FFCONF_H=\"${MICROPY_OOFATFS_DIR}/ffconf.h\"
LFS1_NO_MALLOC LFS1_NO_DEBUG LFS1_NO_WARN LFS1_NO_ERROR LFS1_NO_ASSERT