blob: 4e1e27108fb930a20ad2058de2563c6eff5e5c38 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
cmake_minimum_required(VERSION 3.1)
project(TestFindJsonCpp CXX)
include(CTest)
find_package(JsonCpp REQUIRED)
add_executable(test_jsoncpp_tgt main.cxx)
target_link_libraries(test_jsoncpp_tgt JsonCpp::JsonCpp)
add_test(NAME test_jsoncpp_tgt COMMAND test_jsoncpp_tgt)
add_executable(test_jsoncpp_var main.cxx)
target_include_directories(test_jsoncpp_var PRIVATE ${JsonCpp_INCLUDE_DIRS})
target_link_libraries(test_jsoncpp_var PRIVATE ${JsonCpp_LIBRARIES})
add_test(NAME test_jsoncpp_var COMMAND test_jsoncpp_var)
|