diff options
author | Brad King <brad.king@kitware.com> | 2015-01-16 19:11:38 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2015-01-19 14:34:03 (GMT) |
commit | 0aebeb9c84086b19c56a3ced5c95c60063ab37e2 (patch) | |
tree | a4db2166cabd84853f9c7487c0fe875f59316b38 /Tests/FindJsonCpp/Test/CMakeLists.txt | |
parent | 287070ceb8eda82cf58595c9ea2dde57b0d6d45e (diff) | |
download | CMake-0aebeb9c84086b19c56a3ced5c95c60063ab37e2.zip CMake-0aebeb9c84086b19c56a3ced5c95c60063ab37e2.tar.gz CMake-0aebeb9c84086b19c56a3ced5c95c60063ab37e2.tar.bz2 |
FindJsonCpp: Add module to find JsonCpp package
Diffstat (limited to 'Tests/FindJsonCpp/Test/CMakeLists.txt')
-rw-r--r-- | Tests/FindJsonCpp/Test/CMakeLists.txt | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/Tests/FindJsonCpp/Test/CMakeLists.txt b/Tests/FindJsonCpp/Test/CMakeLists.txt new file mode 100644 index 0000000..4e1e271 --- /dev/null +++ b/Tests/FindJsonCpp/Test/CMakeLists.txt @@ -0,0 +1,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) |