0029589: Configuration - allow MFC samples to be built when OCCT is linked statically
[occt.git] / adm / cmake / vtk.cmake
index f9e268b..c5692fd 100644 (file)
@@ -31,7 +31,7 @@ if (NOT DEFINED 3RDPARTY_VTK_INCLUDE_DIR)
   set (3RDPARTY_VTK_INCLUDE_DIR "" CACHE PATH "The directory containing headers of VTK")
 endif()
 
-if (BUILD_SHARED_LIBS)
+#if (BUILD_SHARED_LIBS)
   # vtk library directory
   if (NOT DEFINED 3RDPARTY_VTK_LIBRARY_DIR)
     set (3RDPARTY_VTK_LIBRARY_DIR "" CACHE PATH "The directory containing VTK libraries")
@@ -41,7 +41,7 @@ if (BUILD_SHARED_LIBS)
   if (WIN32 AND NOT DEFINED 3RDPARTY_VTK_DLL_DIR)
     set (3RDPARTY_VTK_DLL_DIR "" CACHE PATH "The directory containing VTK shared libraries")
   endif()
-endif()
+#endif()
 
 # check 3RDPARTY_VTK_ paths for consistency with specified 3RDPARTY_VTK_DIR
 if (3RDPARTY_VTK_DIR AND EXISTS "${3RDPARTY_VTK_DIR}")
@@ -75,10 +75,10 @@ if (VTK_FOUND)
 
     set (3RDPARTY_VTK_INCLUDE_DIRS)
 
-    if (BUILD_SHARED_LIBS)
+#    if (BUILD_SHARED_LIBS)
       set (3RDPARTY_VTK_LIBRARY_DIRS)
       set (3RDPARTY_VTK_DLL_DIRS)
-    endif()
+#    endif()
 
     foreach (VTK_LIBRARY ${VTK_LIBRARIES})
       string (REGEX MATCH "^vtk" IS_VTK_LIBRARY ${VTK_LIBRARY})
@@ -168,7 +168,7 @@ if (VTK_FOUND)
     set (3RDPARTY_VTK_INCLUDE_DIR "${3RDPARTY_VTK_INCLUDE_DIR}" CACHE PATH "The directory containing headers of VTK" FORCE)
   endif()
 
-  if (BUILD_SHARED_LIBS)
+#  if (BUILD_SHARED_LIBS)
     if (3RDPARTY_VTK_LIBRARY_DIRS)
       list (REMOVE_DUPLICATES 3RDPARTY_VTK_LIBRARY_DIRS)
       list (APPEND 3RDPARTY_LIBRARY_DIRS ${3RDPARTY_VTK_LIBRARY_DIRS})
@@ -186,7 +186,7 @@ if (VTK_FOUND)
         set (3RDPARTY_VTK_DLL_DIR "${3RDPARTY_VTK_DLL_DIR}" CACHE PATH "The directory containing VTK shared libraries" FORCE)
       endif()
     endif()
-  endif()
+#  endif()
 
 if (3RDPARTY_VTK_INCLUDE_DIR AND EXISTS "${3RDPARTY_VTK_INCLUDE_DIR}")
   list (APPEND 3RDPARTY_INCLUDE_DIRS ${3RDPARTY_VTK_INCLUDE_DIR})
@@ -198,14 +198,14 @@ if (BUILD_SHARED_LIBS)
   if (3RDPARTY_VTK_LIBRARY_DIR AND EXISTS "${3RDPARTY_VTK_LIBRARY_DIR}")
     list (APPEND 3RDPARTY_LIBRARY_DIRS ${3RDPARTY_VTK_LIBRARY_DIR})
   else()
-    list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_VTK_LIBRARY_DIR)
+    list (APPEND 3RDPARTY_NO_LIBS 3RDPARTY_VTK_LIBRARY_DIR)
   endif()
 
   if (WIN32)
     if (3RDPARTY_VTK_DLL_DIR OR EXISTS "${3RDPARTY_VTK_DLL_DIR}")
       list (APPEND 3RDPARTY_DLL_DIRS ${3RDPARTY_VTK_DLL_DIR})
     else()
-      list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_VTK_DLL_DIR)
+      list (APPEND 3RDPARTY_NO_DLLS 3RDPARTY_VTK_DLL_DIR)
     endif()
   endif()
 endif()