summaryrefslogtreecommitdiff
path: root/sci-libs/vtk/files/vtk-9.3.0-pdal-2.6.0.patch
diff options
context:
space:
mode:
Diffstat (limited to 'sci-libs/vtk/files/vtk-9.3.0-pdal-2.6.0.patch')
-rw-r--r--sci-libs/vtk/files/vtk-9.3.0-pdal-2.6.0.patch77
1 files changed, 77 insertions, 0 deletions
diff --git a/sci-libs/vtk/files/vtk-9.3.0-pdal-2.6.0.patch b/sci-libs/vtk/files/vtk-9.3.0-pdal-2.6.0.patch
new file mode 100644
index 000000000000..98ab24334fd4
--- /dev/null
+++ b/sci-libs/vtk/files/vtk-9.3.0-pdal-2.6.0.patch
@@ -0,0 +1,77 @@
+From: ccee5db79d6037c4d752b5f29dc30fb0dfd039bf Mon Sep 17 00:00:00 2001
+From: Timothée Couble <timothee.couble@kitware.com>
+From: https://gitlab.kitware.com/vtk/vtk/-/merge_requests/10692
+Date: Fri, 10 Nov 2023 10:03:07 +0100
+Subject: [PATCH 1/2] IOPDAL: Always links with pdalcpp
+
+pdal_base and pdal_utils libraries are removed in PDAL 2.6.0
+link with pdalcpp instead starting from this version.
+---
+ IO/PDAL/CMakeLists.txt | 18 ++++++++++++------
+ 1 file changed, 12 insertions(+), 6 deletions(-)
+
+diff --git a/IO/PDAL/CMakeLists.txt b/IO/PDAL/CMakeLists.txt
+index c31af0410f4..b83a9334109 100644
+--- a/IO/PDAL/CMakeLists.txt
++++ b/IO/PDAL/CMakeLists.txt
+@@ -3,14 +3,20 @@ vtk_module_find_package(PACKAGE PDAL VERSION 2.1)
+ set(classes
+ vtkPDALReader)
+
+-set(pdal_libraries pdal_util)
+-if (APPLE OR WIN32)
++set(pdal_libraries)
++if (PDAL_VERSION VERSION_LESS "2.6")
++ set(pdal_libraries pdal_util)
++ if (APPLE OR WIN32)
++ list(APPEND pdal_libraries
++ pdalcpp)
++ else()
++ list(APPEND pdal_libraries
++ pdal_base)
++ endif()
++else ()
+ list(APPEND pdal_libraries
+ pdalcpp)
+-else()
+- list(APPEND pdal_libraries
+- pdal_base)
+-endif()
++endif ()
+
+ vtk_module_add_module(VTK::IOPDAL
+ CLASSES ${classes})
+--
+GitLab
+
+
+From 5bf45b44760bac09b0079827346e78af38d981af Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Timoth=C3=A9e=20Couble?= <timothee.couble@kitware.com>
+Date: Fri, 10 Nov 2023 10:12:32 +0100
+Subject: [PATCH 2/2] Add support for PDAL 2.0 version
+
+---
+ IO/PDAL/CMakeLists.txt | 9 +++++++++
+ 1 file changed, 9 insertions(+)
+
+diff --git a/IO/PDAL/CMakeLists.txt b/IO/PDAL/CMakeLists.txt
+index b83a9334109..a7027524e4f 100644
+--- a/IO/PDAL/CMakeLists.txt
++++ b/IO/PDAL/CMakeLists.txt
+@@ -23,4 +23,13 @@ vtk_module_add_module(VTK::IOPDAL
+ vtk_module_link(VTK::IOPDAL
+ PRIVATE
+ ${pdal_libraries})
++
++# PDAL 2.0 didn't include interfaces to its exported targets.
++# Resolved in https://github.com/PDAL/PDAL/issues/2262.
++if (PDAL_VERSION VERSION_LESS "2.1")
++ vtk_module_include(VTK::IOPDAL
++ PRIVATE
++ ${PDAL_INCLUDE_DIRS})
++endif ()
++
+ vtk_add_test_mangling(VTK::IOPDAL)
+--
+GitLab
+