Skip to content
Snippets Groups Projects
Commit 6ed62999 authored by Lars Bilke's avatar Lars Bilke
Browse files

[CMake] Use find_package for vtk with components.

parent 999cefb4
No related branches found
No related tags found
No related merge requests found
......@@ -54,7 +54,19 @@ if(NOT OGS_USE_CONAN OR NOT CONAN_CMD)
include_directories(SYSTEM ${Boost_INCLUDE_DIRS})
endif()
find_package(VTK 8.2.0 REQUIRED)
set(VTK_COMPONENTS vtkIOXML)
if(OGS_BUILD_GUI)
set(VTK_COMPONENTS ${VTK_COMPONENTS}
vtkIOImage vtkIOLegacy vtkIOExport vtkIOExportPDF
vtkIOExportOpenGL2 vtkInteractionStyle vtkInteractionWidgets
vtkGUISupportQt vtkRenderingOpenGL2 vtkRenderingContextOpenGL2
vtkFiltersTexture vtkRenderingCore
)
endif()
if(OGS_USE_MPI)
set(VTK_COMPONENTS ${VTK_COMPONENTS} vtkIOParallelXML vtkParallelMPI)
endif()
find_package(VTK 8.2.0 REQUIRED COMPONENTS ${VTK_COMPONENTS})
include(${VTK_USE_FILE})
find_package(Eigen3 3.3.4 REQUIRED)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment