cancel
Showing results for 
Search instead for 
Did you mean: 

Unable to build project with netxduo *using CMake*, missing include directory common/drivers

jerry_sandc
Associate III

Hello,

i'm using cmake to build complete STM32F7 application.  I was very happy to see cmake files in x-cube-azrtos-f7.  The threadx, netxduo, and filex libraries themselves build find with cmake.  The problem is when I am building the example project fo NxWebServer using cmake, it can't find a header file in nextduo/common/drivers/inc, since the cmake file for netxduo/common doesn't add this as a include directory.   The IDE (eclipse-based) project in the example project builds fine, since the include directory is the project list.  

https://github.com/STMicroelectronics/x-cube-azrtos-f7/tree/main/Middlewares/ST/netxduo/common

I opened issue in github but any advice welcome ahead of time.

https://github.com/STMicroelectronics/x-cube-azrtos-f7/issues/2

1 REPLY 1
jerry_sandc
Associate III
# ThreadX library
set(THREADX_ARCH cortex_m7)
set(THREADX_TOOLCHAIN gnu)

# specify out of tree source build so each library can pickup the user variables (i.e. *_USER_FILE)
add_subdirectory(${CMAKE_SOURCE_DIR}/x-cube-azrtos-f7/Middlewares/ST/threadx example_app_threadx)
add_subdirectory(${CMAKE_SOURCE_DIR}/x-cube-azrtos-f7/Middlewares/ST/netxduo example_app_netxduo )
add_subdirectory(${CMAKE_SOURCE_DIR}/x-cube-azrtos-f7/Middlewares/ST/filex   example_app_filex)


################## PROJECT SETUP ######################################
project(stm32f769i-eval_app C ASM)

message(STATUS "CMAKE_EXECUTABLE_SUFFIX ${CMAKE_EXECUTABLE_SUFFIX}")

add_executable(${PROJECT_NAME} ${PROJECT_SOURCES})
target_link_libraries (${PROJECT_NAME}
                       stm32f7_hal
                       STM32F769I_EVAL
                       Comp-mfxstm32l152
                       threadx
                       netxduo
                       filex )