From 3799e0922d14c6e44f0356e0108e6967fa25d55c Mon Sep 17 00:00:00 2001 From: Huang Qi Date: Sun, 3 Nov 2024 21:06:28 +0800 Subject: [PATCH] wamr: add iwasm include directory to nuttx target This patch allow from other module that outside WAMR directory include `wasm_export.h` to use WAMR as library. Signed-off-by: Huang Qi --- interpreters/wamr/CMakeLists.txt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/interpreters/wamr/CMakeLists.txt b/interpreters/wamr/CMakeLists.txt index 1fe37c878..827f13af0 100644 --- a/interpreters/wamr/CMakeLists.txt +++ b/interpreters/wamr/CMakeLists.txt @@ -47,6 +47,12 @@ if(CONFIG_INTERPRETERS_WAMR) nuttx_add_library(wamr STATIC) + set_property( + TARGET nuttx + APPEND + PROPERTY NUTTX_INCLUDE_DIRECTORIES + ${CMAKE_CURRENT_SOURCE_DIR}/wamr/core/iwasm/include) + include(${WAMR_DIR}/product-mini/platforms/nuttx/CMakeLists.txt) target_sources(wamr PRIVATE ${WAMR_SOURCES}) target_compile_options(wamr PRIVATE ${WAMR_CFLAGS})