diff Applications/Samples/RtViewerPlugin/CMakeLists.txt @ 1836:5a6adbc20ace

cleanup cmake
author Sebastien Jodogne <s.jodogne@gmail.com>
date Sat, 12 Jun 2021 13:43:42 +0200
parents b05d5f0d014f
children c01ed7a7c11f
line wrap: on
line diff
--- a/Applications/Samples/RtViewerPlugin/CMakeLists.txt	Sat Jun 12 09:01:40 2021 +0200
+++ b/Applications/Samples/RtViewerPlugin/CMakeLists.txt	Sat Jun 12 13:43:42 2021 +0200
@@ -54,6 +54,17 @@
 include_directories(${ORTHANC_FRAMEWORK_ROOT})
 
 if (ORTHANC_FRAMEWORK_SOURCE STREQUAL "system")
+  if (ORTHANC_FRAMEWORK_USE_SHARED)
+    include(FindBoost)
+    find_package(Boost COMPONENTS system)
+    
+    if (NOT Boost_FOUND)
+      message(FATAL_ERROR "Unable to locate Boost on this system")
+    endif()
+    
+    link_libraries(${Boost_LIBRARIES} jsoncpp)
+  endif()
+
   link_libraries(${ORTHANC_FRAMEWORK_LIBRARIES})
 
 else()