git: dd567b32c6a8 - main - science/paraview: Fix build after recent upgrade of math/exprtk

From: Yuri Victorovich <yuri_at_FreeBSD.org>
Date: Sat, 11 Mar 2023 22:38:47 UTC
The branch main has been updated by yuri:

URL: https://cgit.FreeBSD.org/ports/commit/?id=dd567b32c6a831801869ee36d4e932044180f8d1

commit dd567b32c6a831801869ee36d4e932044180f8d1
Author:     Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2023-03-11 22:35:55 +0000
Commit:     Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2023-03-11 22:38:45 +0000

    science/paraview: Fix build after recent upgrade of math/exprtk
    
    FindExprTk.cmake parses the header file exprtk.h to find version,
    but the type of this variable changed since exprtk-0.0.2
    
    Reported by:    thierry@
---
 science/paraview/files/patch-VTK_CMake_FindExprTk.cmake | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/science/paraview/files/patch-VTK_CMake_FindExprTk.cmake b/science/paraview/files/patch-VTK_CMake_FindExprTk.cmake
new file mode 100644
index 000000000000..215a8fb90f6f
--- /dev/null
+++ b/science/paraview/files/patch-VTK_CMake_FindExprTk.cmake
@@ -0,0 +1,15 @@
+- workaround for https://gitlab.kitware.com/paraview/paraview/-/issues/21817
+
+--- VTK/CMake/FindExprTk.cmake.orig	2023-03-11 22:27:31 UTC
++++ VTK/CMake/FindExprTk.cmake
+@@ -21,8 +21,8 @@ mark_as_advanced(ExprTk_INCLUDE_DIR)
+ 
+ if (ExprTk_INCLUDE_DIR)
+   file(STRINGS "${ExprTk_INCLUDE_DIR}/exprtk.hpp" _exprtk_version_header
+-    REGEX "static const char\\* version")
+-  string(REGEX MATCH "static const char\\* version = \"([0-9.]+)\"" _exprtk_version_match "${_exprtk_version_header}")
++    REGEX "static char_cptr *version")
++  string(REGEX MATCH "static char_cptr *version = \"([0-9.]+)\"" _exprtk_version_match "${_exprtk_version_header}")
+   set(ExprTk_VERSION "${CMAKE_MATCH_1}")
+   unset(_exprtk_version_header)
+   unset(_exprtk_version_match)