summaryrefslogtreecommitdiff
path: root/libre/opencv/vtk9.patch
diff options
context:
space:
mode:
Diffstat (limited to 'libre/opencv/vtk9.patch')
-rw-r--r--libre/opencv/vtk9.patch36
1 files changed, 36 insertions, 0 deletions
diff --git a/libre/opencv/vtk9.patch b/libre/opencv/vtk9.patch
new file mode 100644
index 000000000..206442b39
--- /dev/null
+++ b/libre/opencv/vtk9.patch
@@ -0,0 +1,36 @@
+diff --git a/cmake/OpenCVDetectVTK.cmake b/cmake/OpenCVDetectVTK.cmake
+index 312fd41fe4..aeda80d47c 100644
+--- a/cmake/OpenCVDetectVTK.cmake
++++ b/cmake/OpenCVDetectVTK.cmake
+@@ -1,8 +1,5 @@
+ if(NOT VTK_FOUND)
+- find_package(VTK QUIET NAMES vtk VTK)
+- if(VTK_FOUND)
+- if(NOT (VTK_VERSION VERSION_LESS "9.0.0") AND (VTK_VERSION VERSION_LESS "10.0.0")) # VTK 9.x
+- find_package(VTK 9 QUIET NAMES vtk COMPONENTS
++ find_package(VTK 9 QUIET NAMES vtk COMPONENTS
+ FiltersExtraction
+ FiltersSources
+ FiltersTexture
+@@ -14,21 +11,6 @@ if(NOT VTK_FOUND)
+ RenderingLOD
+ RenderingOpenGL2
+ NO_MODULE)
+- elseif(VTK_VERSION VERSION_GREATER "5") # VTK 6.x components
+- find_package(VTK QUIET COMPONENTS vtkInteractionStyle vtkRenderingLOD vtkIOPLY vtkFiltersTexture vtkRenderingFreeType vtkIOExport NO_MODULE)
+- IF(VTK_FOUND)
+- IF(VTK_RENDERING_BACKEND) #in vtk 7, the rendering backend is exported as a var.
+- find_package(VTK QUIET COMPONENTS vtkRendering${VTK_RENDERING_BACKEND} vtkInteractionStyle vtkRenderingLOD vtkIOPLY vtkFiltersTexture vtkRenderingFreeType vtkIOExport vtkIOGeometry NO_MODULE)
+- ELSE(VTK_RENDERING_BACKEND)
+- find_package(VTK QUIET COMPONENTS vtkRenderingOpenGL vtkInteractionStyle vtkRenderingLOD vtkIOPLY vtkFiltersTexture vtkRenderingFreeType vtkIOExport NO_MODULE)
+- ENDIF(VTK_RENDERING_BACKEND)
+- ENDIF(VTK_FOUND)
+- elseif(VTK_VERSION VERSION_EQUAL "5") # VTK 5.x components
+- find_package(VTK QUIET COMPONENTS vtkCommon NO_MODULE)
+- else()
+- set(VTK_FOUND FALSE)
+- endif()
+- endif()
+ endif()
+
+ if(NOT VTK_FOUND)