Skip to content

Commit

Permalink
* FIX [demo/quic] Fix the error in building quic demo.
Browse files Browse the repository at this point in the history
Signed-off-by: wanghaemq <[email protected]>
  • Loading branch information
wanghaEMQ committed May 6, 2024
1 parent e5516c1 commit 9d98d29
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
7 changes: 5 additions & 2 deletions demo/quic_mqtt/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,11 @@ cmake_minimum_required(VERSION 3.13)

project(quic_client)

if (BUILD_DEMO)
else ()
# Call this from your own project's makefile.
find_package(nng CONFIG REQUIRED)
find_package(nng CONFIG REQUIRED)
endif (BUILD_DEMO)

find_package(Threads)
find_package(msquic)
Expand All @@ -35,7 +38,7 @@ if(OPENSSL_FOUND)
target_link_libraries(quic_client OpenSSL::Crypto OpenSSL::SSL)
endif()

target_link_libraries(quic_client nng::nng msquic pthread)
target_link_libraries(quic_client nng msquic pthread)
target_compile_definitions(quic_client PRIVATE NNG_ELIDE_DEPRECATED)

if (NNG_ENABLE_SQLITE)
Expand Down
7 changes: 5 additions & 2 deletions demo/quic_mqttv5/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,11 @@ cmake_minimum_required(VERSION 3.13)

project(quic_clientv5)

if (BUILD_DEMO)
else ()
# Call this from your own project's makefile.
find_package(nng CONFIG REQUIRED)
find_package(nng CONFIG REQUIRED)
endif (BUILD_DEMO)

find_package(Threads)
find_package(msquic)
Expand All @@ -35,7 +38,7 @@ if(OPENSSL_FOUND)
target_link_libraries(quic_client_v5 OpenSSL::Crypto OpenSSL::SSL)
endif()

target_link_libraries(quic_client_v5 nng::nng msquic pthread)
target_link_libraries(quic_client_v5 nng msquic pthread)
target_compile_definitions(quic_client_v5 PRIVATE NNG_ELIDE_DEPRECATED)

if (NNG_ENABLE_SQLITE)
Expand Down

0 comments on commit 9d98d29

Please sign in to comment.