nats.zig/deps/nats.c/test/dylib/CMakeLists.txt
torque 79a45fd2e3
git subrepo clone (merge) --branch=v3.6.1 https://github.com/nats-io/nats.c.git deps/nats.c
subrepo:
  subdir:   "deps/nats.c"
  merged:   "66cec7f"
upstream:
  origin:   "https://github.com/nats-io/nats.c.git"
  branch:   "v3.6.1"
  commit:   "66cec7f"
git-subrepo:
  version:  "0.4.6"
  commit:   "b8b46501e"
2023-08-15 00:21:33 -07:00

18 lines
362 B
CMake

if(NOT BUILD_TESTING)
return()
endif()
if(NOT NATS_BUILD_LIB_SHARED)
return()
endif()
# We need this to build the test program
include_directories(${PROJECT_SOURCE_DIR}/src)
# Build the test program
add_executable(nonats nonats.c)
# Link dynamically with the library
add_definitions(-Dnats_IMPORTS)
target_link_libraries(nonats nats ${NATS_EXTRA_LIB})