[packages/vtk] fix build with freetype >= 2.10.3

atler atler at pld-linux.org
Sun Nov 22 15:00:48 CET 2020


commit aed6aa398d0fbd0b2f1ef6b539a8ca2895dadf4b
Author: Jan Palus <atler at pld-linux.org>
Date:   Sun Nov 22 14:59:39 2020 +0100

    fix build with freetype >= 2.10.3
    
    from https://gitlab.kitware.com/vtk/vtk/-/issues/18033

 freetype.patch | 33 +++++++++++++++++++++++++++++++++
 vtk.spec       |  2 ++
 2 files changed, 35 insertions(+)
---
diff --git a/vtk.spec b/vtk.spec
index 01eb3ea..67305bb 100644
--- a/vtk.spec
+++ b/vtk.spec
@@ -33,6 +33,7 @@ Patch3:		qt-5.15.patch
 Patch4:		python-3.8.patch
 Patch5:		link.patch
 Patch6:		system-pugixml.patch
+Patch7:		freetype.patch
 URL:		http://www.vtk.org/
 %{?with_OSMesa:BuildRequires: Mesa-libOSMesa-devel}
 BuildRequires:	OpenGL-GLX-devel
@@ -312,6 +313,7 @@ potrzebne do uruchamiania różnych przykładów z pakietu vtk-examples.
 %patch4 -p1
 %patch5 -p1
 %patch6 -p1
+%patch7 -p1
 
 # Replace relative path ../../../VTKData with destination filesystem path
 grep -Erl '(\.\./)+VTKData' Examples | xargs \
diff --git a/freetype.patch b/freetype.patch
new file mode 100644
index 0000000..80d4932
--- /dev/null
+++ b/freetype.patch
@@ -0,0 +1,33 @@
+--- VTK-8.2.0/Rendering/FreeType/vtkFreeTypeTools.cxx.orig	2019-01-30 18:15:13.000000000 +0100
++++ VTK-8.2.0/Rendering/FreeType/vtkFreeTypeTools.cxx	2020-10-17 00:21:55.153442255 +0200
+@@ -387,7 +387,7 @@ FTC_CMapCache* vtkFreeTypeTools::GetCMap
+ }
+ 
+ //----------------------------------------------------------------------------
+-FT_CALLBACK_DEF(FT_Error)
++extern "C" FT_Error
+ vtkFreeTypeToolsFaceRequester(FTC_FaceID face_id,
+                               FT_Library lib,
+                               FT_Pointer request_data,
+--- VTK-8.2.0/Rendering/FreeTypeFontConfig/vtkFontConfigFreeTypeTools.cxx.orig	2019-01-30 18:15:13.000000000 +0100
++++ VTK-8.2.0/Rendering/FreeTypeFontConfig/vtkFontConfigFreeTypeTools.cxx	2020-10-17 00:38:23.457937944 +0200
+@@ -26,10 +26,8 @@
+ 
+ vtkStandardNewMacro(vtkFontConfigFreeTypeTools)
+ 
+-namespace
+-{
+ // The FreeType face requester callback:
+-FT_CALLBACK_DEF(FT_Error)
++extern "C" FT_Error
+ vtkFontConfigFreeTypeToolsFaceRequester(FTC_FaceID face_id,
+                                         FT_Library lib,
+                                         FT_Pointer request_data,
+@@ -75,7 +73,6 @@ vtkFontConfigFreeTypeToolsFaceRequester(
+ 
+   return static_cast<FT_Error>(0);
+ }
+-} // end anon namespace
+ 
+ void vtkFontConfigFreeTypeTools::PrintSelf(ostream &os, vtkIndent indent)
+ {
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/vtk.git/commitdiff/aed6aa398d0fbd0b2f1ef6b539a8ca2895dadf4b



More information about the pld-cvs-commit mailing list