aboutsummaryrefslogtreecommitdiff
path: root/src/transport
diff options
context:
space:
mode:
Diffstat (limited to 'src/transport')
-rw-r--r--src/transport/zerotier/CMakeLists.txt20
1 files changed, 4 insertions, 16 deletions
diff --git a/src/transport/zerotier/CMakeLists.txt b/src/transport/zerotier/CMakeLists.txt
index bc8673c5..167a98c0 100644
--- a/src/transport/zerotier/CMakeLists.txt
+++ b/src/transport/zerotier/CMakeLists.txt
@@ -15,10 +15,6 @@ mark_as_advanced(NNG_TRANSPORT_ZEROTIER)
if (NNG_TRANSPORT_ZEROTIER)
- # The zerotiercore project will have been found at the top level
- # of the package. This is necessary because import libraries cannot
- # percolate back to the parent tree.
-
# NB: As we wind up linking libzerotiercore.a into the application,
# this means that your application will *also* need to either be licensed
# under the GPLv3, or you will need to have a commercial license from
@@ -31,17 +27,9 @@ if (NNG_TRANSPORT_ZEROTIER)
************************************************************")
find_package(zerotiercore REQUIRED)
- set(_PKGS zerotiercore)
- set(_LIBS zerotiercore::zerotiercore)
- set(_DEFS -DNNG_TRANSPORT_ZEROTIER)
-
- set(_SRCS transport/zerotier/zerotier.c
- transport/zerotier/zthash.c
- ${PROJECT_SOURCE_DIR}/include/nng/transport/zerotier/zerotier.h)
-
- set(NNG_DEFS ${NNG_DEFS} ${_DEFS} PARENT_SCOPE)
- set(NNG_LIBS ${NNG_LIBS} ${_LIBS} PARENT_SCOPE)
- set(NNG_PKGS ${NNG_PKGS} ${_PKGS} PARENT_SCOPE)
- set(NNG_SRCS ${NNG_SRCS} ${_SRCS} PARENT_SCOPE)
+ nng_link_libraries(zerotiercore::zerotiercore)
+ nng_defines(NNG_TRANSPORT_ZEROTIER)
+ nng_sources(zerotier.c zthash.c)
+ nng_headers(nng/transport/zerotier/zerotier.h)
endif()