CMakeLists.txt: fix include path for coap-rd

coap-rd uses uthash.h from the internal libcoap API. Therefore,
"include/coap3" is additionally passed as include path for target
coap-rd.
This commit is contained in:
Olaf Bergmann committed 2021-04-29 13:47:12 +02:00
1 parent f6eede8077
commit 4ff2d85f33
1 file changed
+3
+3
View File
@@ -551,6 +551,9 @@ if(ENABLE_EXAMPLES)
PUBLIC ${PROJECT_NAME}::${COAP_LIBRARY_NAME})
add_executable(coap-rd ${CMAKE_CURRENT_LIST_DIR}/examples/coap-rd.c)
target_include_directories(coap-rd
PRIVATE
$<BUILD_INTERFACE:${CMAKE_CURRENT_LIST_DIR}/include/coap${LIBCOAP_API_VERSION}>)
target_link_libraries(coap-rd PUBLIC ${PROJECT_NAME}::${COAP_LIBRARY_NAME})
add_executable(coap-server ${CMAKE_CURRENT_LIST_DIR}/examples/coap-server.c)