GNU bug report logs - #76269
[PATCH] gnu: vtk: Update to 9.4.1

Previous Next

Package: guix-patches;

Reported by: Lars Bilke <lars.bilke <at> ufz.de>

Date: Thu, 13 Feb 2025 14:39:01 UTC

Severity: normal

Tags: patch

To reply to this bug, email your comments to 76269 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#76269; Package guix-patches. (Thu, 13 Feb 2025 14:39:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Lars Bilke <lars.bilke <at> ufz.de>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Thu, 13 Feb 2025 14:39:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Lars Bilke <lars.bilke <at> ufz.de>
To: guix-patches <at> gnu.org
Cc: Lars Bilke <lars.bilke <at> ufz.de>
Subject: [PATCH] gnu: vtk: Update to 9.4.1
Date: Thu, 13 Feb 2025 15:38:14 +0100
* gnu/packages/image-processing.scm (vtk): Update to 9.4.1.

Change-Id: Ife39df610c4487683a5c8d72b60eb750530c1358
---
 gnu/packages/image-processing.scm | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/gnu/packages/image-processing.scm b/gnu/packages/image-processing.scm
index 20e188bd70..cf29bf22f5 100644
--- a/gnu/packages/image-processing.scm
+++ b/gnu/packages/image-processing.scm
@@ -323,7 +323,7 @@ (define-public opencolorio
 (define-public vtk
   (package
     (name "vtk")
-    (version "9.3.0")
+    (version "9.4.1")
     (source (origin
               (method url-fetch)
               (uri (string-append "https://vtk.org/files/release/"
@@ -331,7 +331,7 @@ (define-public vtk
                                   "/VTK-" version ".tar.gz"))
               (sha256
                (base32
-                "1s8vd34nhrgnw1bf9zhfn062d53fwq3csjfwvm7lxcr5a8lvkizx"))
+                "0aa5pkw2xxzksl48ldbj3cq6r4y4mxvcpl66f64gkah2s34b0ly2"))
               (modules '((guix build utils)))
               (snippet
                '(begin
@@ -341,7 +341,7 @@ (define-public vtk
                       (string-append "ThirdParty/" dir "/vtk" dir)))
                    ;; pugixml depended upon unconditionally
                    '("doubleconversion" "eigen" "expat" "freetype" "gl2ps"
-                     "glew" "hdf5" "jpeg" "jsoncpp" "libharu" "libproj"
+                     "hdf5" "jpeg" "jsoncpp" "libharu" "libproj"
                      "libxml2" "lz4" "netcdf" "ogg" "png" "sqlite" "theora"
                      "tiff" "zlib"))
                   (substitute* "IO/ExportPDF/vtkPDFContextDevice2D.cxx"
@@ -360,7 +360,6 @@ (define-public vtk
                "-DVTK_MODULE_USE_EXTERNAL_VTK_expat=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_freetype=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_gl2ps=ON"
-               "-DVTK_MODULE_USE_EXTERNAL_VTK_glew=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_hdf5=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_jpeg=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_jsoncpp=ON"
@@ -380,7 +379,7 @@ (define-public vtk
                "-DVTK_WRAP_PYTHON=ON"
                "-DVTK_PYTHON_VERSION:STRING=3"
 
-               "-DVTK_SMP_ENABLE_OPENNMP=ON"
+               "-DVTK_SMP_ENABLE_OPENMP=ON"
                "-DVTK_SMP_ENABLE_TBB=ON"
                "-DVTK_USE_MPI=ON"
                #$@(if (target-riscv64?)

base-commit: bcce7f8fa8b821b76591b297f61d473c5972e397
-- 
2.46.1





Information forwarded to guix-patches <at> gnu.org:
bug#76269; Package guix-patches. (Tue, 18 Feb 2025 17:20:03 GMT) Full text and rfc822 format available.

Message #8 received at 76269 <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludovic.courtes <at> inria.fr>
To: Lars Bilke <lars.bilke <at> ufz.de>
Cc: 76269 <at> debbugs.gnu.org
Subject: Re: [bug#76269] [PATCH] gnu: vtk: Update to 9.4.1
Date: Tue, 18 Feb 2025 18:19:26 +0100
Hi Lars,

Lars Bilke <lars.bilke <at> ufz.de> skribis:

> * gnu/packages/image-processing.scm (vtk): Update to 9.4.1.
>
> Change-Id: Ife39df610c4487683a5c8d72b60eb750530c1358

Apparently this breaks at least freecad:

--8<---------------cut here---------------start------------->8---
cd /tmp/guix-build-freecad-1.0.0.drv-0/build/src/Mod/CAM && /gnu/store/2lxfijiqqljxdxr2ppqqrn5czkh4r1rq-cmake-minimal-3.24.2/bin/cmake -E copy /tmp/guix-build-freecad-1.0.0.drv-0/source/src/Mod/CAM/Path/Op/Util.py /tmp/guix-build-freecad-1.0.0.drv-0/build/Mod/CAM/Path/Op/Util.py
/tmp/guix-build-freecad-1.0.0.drv-0/source/src/3rdParty/salomesmesh/src/SMDS/SMDS_UnstructuredGrid.cpp: In member function ‘void SMDS_UnstructuredGrid::BuildLinks()’:
/tmp/guix-build-freecad-1.0.0.drv-0/source/src/3rdParty/salomesmesh/src/SMDS/SMDS_UnstructuredGrid.cpp:1030:25: error: no matching function for call to ‘vtkCellLinks::BuildLinks(SMDS_UnstructuredGrid*)’
 1030 |   GetLinks()->BuildLinks(this);
      |   ~~~~~~~~~~~~~~~~~~~~~~^~~~~~
In file included from /tmp/guix-build-freecad-1.0.0.drv-0/source/src/3rdParty/salomesmesh/inc/SMDS_UnstructuredGrid.hxx:30,
                 from /tmp/guix-build-freecad-1.0.0.drv-0/source/src/3rdParty/salomesmesh/src/SMDS/SMDS_UnstructuredGrid.cpp:20:
/gnu/store/gr8mwbl3zlx9hc4x9k5s9sgcy2kp4sr9-vtk-9.4.1/include/vtk-9.4/vtkCellLinks.h:64:8: note: candidate: ‘virtual void vtkCellLinks::BuildLinks()’
   64 |   void BuildLinks() override;
      |        ^~~~~~~~~~
/gnu/store/gr8mwbl3zlx9hc4x9k5s9sgcy2kp4sr9-vtk-9.4.1/include/vtk-9.4/vtkCellLinks.h:64:8: note:   candidate expects 0 arguments, 1 provided
--8<---------------cut here---------------end--------------->8---

Could you take a look?  (Perhaps the solution will be to retain the
previous version of VTK for use in packages like this one.)

More generally, could you test with:

  guix build -P1 vtk <at> 9.4.1 -P1 vtk <at> 7

?

Dependent packages like ‘python-fenics-fiat’ are already broken, so it’s
“okay” to keep them broken.

Thanks,
Ludo’.




Information forwarded to guix-patches <at> gnu.org:
bug#76269; Package guix-patches. (Mon, 24 Feb 2025 08:44:01 GMT) Full text and rfc822 format available.

Message #11 received at 76269 <at> debbugs.gnu.org (full text, mbox):

From: Lars Bilke <lars.bilke <at> ufz.de>
To: 76269 <at> debbugs.gnu.org
Cc: Lars Bilke <lars.bilke <at> ufz.de>
Subject: [PATCH 1/2] gnu: vtk: Update to 9.4.1
Date: Mon, 24 Feb 2025 09:43:33 +0100
* gnu/packages/image-processing.scm (vtk): Update to 9.4.1.

Change-Id: Ife39df610c4487683a5c8d72b60eb750530c1358
---
 gnu/packages/image-processing.scm | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/gnu/packages/image-processing.scm b/gnu/packages/image-processing.scm
index 405f90ca9a..a456d94863 100644
--- a/gnu/packages/image-processing.scm
+++ b/gnu/packages/image-processing.scm
@@ -323,7 +323,7 @@ (define-public opencolorio
 (define-public vtk
   (package
     (name "vtk")
-    (version "9.3.0")
+    (version "9.4.1")
     (source (origin
               (method url-fetch)
               (uri (string-append "https://vtk.org/files/release/"
@@ -331,7 +331,7 @@ (define-public vtk
                                   "/VTK-" version ".tar.gz"))
               (sha256
                (base32
-                "1s8vd34nhrgnw1bf9zhfn062d53fwq3csjfwvm7lxcr5a8lvkizx"))
+                "0aa5pkw2xxzksl48ldbj3cq6r4y4mxvcpl66f64gkah2s34b0ly2"))
               (modules '((guix build utils)))
               (snippet
                '(begin
@@ -341,7 +341,7 @@ (define-public vtk
                       (string-append "ThirdParty/" dir "/vtk" dir)))
                    ;; pugixml depended upon unconditionally
                    '("doubleconversion" "eigen" "expat" "freetype" "gl2ps"
-                     "glew" "hdf5" "jpeg" "jsoncpp" "libharu" "libproj"
+                     "hdf5" "jpeg" "jsoncpp" "libharu" "libproj"
                      "libxml2" "lz4" "netcdf" "ogg" "png" "sqlite" "theora"
                      "tiff" "zlib"))
                   (substitute* "IO/ExportPDF/vtkPDFContextDevice2D.cxx"
@@ -360,7 +360,6 @@ (define-public vtk
                "-DVTK_MODULE_USE_EXTERNAL_VTK_expat=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_freetype=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_gl2ps=ON"
-               "-DVTK_MODULE_USE_EXTERNAL_VTK_glew=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_hdf5=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_jpeg=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_jsoncpp=ON"
@@ -380,7 +379,7 @@ (define-public vtk
                "-DVTK_WRAP_PYTHON=ON"
                "-DVTK_PYTHON_VERSION:STRING=3"
 
-               "-DVTK_SMP_ENABLE_OPENNMP=ON"
+               "-DVTK_SMP_ENABLE_OPENMP=ON"
                "-DVTK_SMP_ENABLE_TBB=ON"
                "-DVTK_USE_MPI=ON"
                #$@(if (target-riscv64?)

base-commit: c4fcf8fb627c9ea54a4a639a81766e5df3973fdc
-- 
2.46.1





Information forwarded to csantosb <at> inventati.org, maxim.cournoyer <at> gmail.com, guix-patches <at> gnu.org:
bug#76269; Package guix-patches. (Mon, 24 Feb 2025 08:44:02 GMT) Full text and rfc822 format available.

Message #14 received at 76269 <at> debbugs.gnu.org (full text, mbox):

From: Lars Bilke <lars.bilke <at> ufz.de>
To: 76269 <at> debbugs.gnu.org
Cc: Lars Bilke <lars.bilke <at> ufz.de>
Subject: [PATCH 2/2] gnu: freecad: Add vtk 9.4.1 patch.
Date: Mon, 24 Feb 2025 09:43:34 +0100
* gnu/packages/engineering.scm (freecad): Add vtk 9.4.1 patch.
* gnu/local.mk: Add freecad vtk 9.4.1 patch to list.

Change-Id: I9220aec757c2331a2dfa3eee9d0b84f774785de3
---
 gnu/local.mk                              |  1 +
 gnu/packages/engineering.scm              |  1 +
 gnu/packages/patches/freecad-vtk941.patch | 71 +++++++++++++++++++++++
 3 files changed, 73 insertions(+)
 create mode 100644 gnu/packages/patches/freecad-vtk941.patch

diff --git a/gnu/local.mk b/gnu/local.mk
index 45a9cb635e..35e1b5e6b6 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1317,6 +1317,7 @@ dist_patch_DATA =						\
   %D%/packages/patches/fpc-reproducibility.patch		\
   %D%/packages/patches/fpc-glibc-2.34-compat.patch		\
   %D%/packages/patches/fpm-newer-clamp-fix.patch		\
+  %D%/packages/patches/freecad-vtk941.patch	\
   %D%/packages/patches/freedict-tools-fix-determinism.patch	\
   %D%/packages/patches/freedink-engine-fix-sdl-hints.patch	\
   %D%/packages/patches/freeimage-libtiff-compat.patch		\
diff --git a/gnu/packages/engineering.scm b/gnu/packages/engineering.scm
index 234f4a2b03..d4d920cd08 100644
--- a/gnu/packages/engineering.scm
+++ b/gnu/packages/engineering.scm
@@ -3173,6 +3173,7 @@ (define-public freecad
        (file-name (git-file-name name version))
        (sha256
         (base32 "0wwymcfgi0cybj7m6awflk8c7n6iy97lpgpfhfncx3zwvjrxv588"))
+       (patches (search-patches "freecad-vtk941.patch"))  ;; remove on 1.1 release
        (modules '((guix build utils)))
        (snippet
         '(begin
diff --git a/gnu/packages/patches/freecad-vtk941.patch b/gnu/packages/patches/freecad-vtk941.patch
new file mode 100644
index 0000000000..e05548a599
--- /dev/null
+++ b/gnu/packages/patches/freecad-vtk941.patch
@@ -0,0 +1,71 @@
+From fafff3a08b7a6212ce3417e08b18cb2fc8e7e868 Mon Sep 17 00:00:00 2001
+From: wmayer <wmayer <at> freecad.org>
+Date: Mon, 16 Dec 2024 10:56:43 +0100
+Subject: [PATCH] smesh: Fix build failure with vtk 9.4
+
+Fixes #18423
+---
+ .../src/SMDS/SMDS_UnstructuredGrid.cpp          | 17 ++++++++++-------
+ 1 file changed, 10 insertions(+), 7 deletions(-)
+
+diff --git a/src/3rdParty/salomesmesh/src/SMDS/SMDS_UnstructuredGrid.cpp b/src/3rdParty/salomesmesh/src/SMDS/SMDS_UnstructuredGrid.cpp
+index e9895d615717..4e9d6dc05764 100644
+--- a/src/3rdParty/salomesmesh/src/SMDS/SMDS_UnstructuredGrid.cpp
++++ b/src/3rdParty/salomesmesh/src/SMDS/SMDS_UnstructuredGrid.cpp
+@@ -32,6 +32,7 @@
+ #include <vtkDoubleArray.h>
+ #include <vtkIdTypeArray.h>
+ #include <vtkUnsignedCharArray.h>
++#include <vtkVersionMacros.h>
+ 
+ #include <list>
+ #include <climits>
+@@ -249,14 +250,16 @@ void SMDS_UnstructuredGrid::compactGrid(std::vector<int>& idNodesOldToNew, int n
+     }
+   }
+ 
+-  if (this->FaceLocations)
++  vtkIdTypeArray* thisFaceLocations = GetFaceLocations();
++  vtkIdTypeArray* thisFaces = GetFaces();
++  if (thisFaceLocations)
+     {
+       vtkIdTypeArray *newFaceLocations = vtkIdTypeArray::New();
+       newFaceLocations->Initialize();
+       newFaceLocations->Allocate(newTypes->GetSize());
+       vtkIdTypeArray *newFaces = vtkIdTypeArray::New();
+       newFaces->Initialize();
+-      newFaces->Allocate(this->Faces->GetSize());
++      newFaces->Allocate(thisFaces->GetSize());
+       for (int i = 0; i < oldCellSize; i++)
+         {
+           if (this->Types->GetValue(i) == VTK_EMPTY_CELL)
+@@ -265,16 +268,16 @@ void SMDS_UnstructuredGrid::compactGrid(std::vector<int>& idNodesOldToNew, int n
+           if (newTypes->GetValue(newCellId) == VTK_POLYHEDRON)
+             {
+                newFaceLocations->InsertNextValue(newFaces->GetMaxId()+1);
+-               int oldFaceLoc = this->FaceLocations->GetValue(i);
+-               int nCellFaces = this->Faces->GetValue(oldFaceLoc++);
++               int oldFaceLoc = thisFaceLocations->GetValue(i);
++               int nCellFaces = thisFaces->GetValue(oldFaceLoc++);
+                newFaces->InsertNextValue(nCellFaces);
+                for (int n=0; n<nCellFaces; n++)
+                  {
+-                   int nptsInFace = this->Faces->GetValue(oldFaceLoc++);
++                   int nptsInFace = thisFaces->GetValue(oldFaceLoc++);
+                    newFaces->InsertNextValue(nptsInFace);
+                    for (int k=0; k<nptsInFace; k++)
+                      {
+-                       int oldpt = this->Faces->GetValue(oldFaceLoc++);
++                       int oldpt = thisFaces->GetValue(oldFaceLoc++);
+                        newFaces->InsertNextValue(idNodesOldToNew[oldpt]);
+                      }
+                  }
+@@ -292,7 +295,7 @@ void SMDS_UnstructuredGrid::compactGrid(std::vector<int>& idNodesOldToNew, int n
+     }
+   else
+   {
+-    this->SetCells(newTypes, newLocations, newConnectivity, FaceLocations, Faces);
++    this->SetCells(newTypes, newLocations, newConnectivity, thisFaceLocations, thisFaces);
+   }
+ 
+   newPoints->Delete();
\ No newline at end of file
-- 
2.46.1





Information forwarded to guix-patches <at> gnu.org:
bug#76269; Package guix-patches. (Mon, 24 Feb 2025 08:49:02 GMT) Full text and rfc822 format available.

Message #17 received at 76269 <at> debbugs.gnu.org (full text, mbox):

From: Lars Bilke <lars.bilke <at> ufz.de>
To: Ludovic Courtès <ludovic.courtes <at> inria.fr>
Cc: 76269 <at> debbugs.gnu.org
Subject: Re: [bug#76269] [PATCH] gnu: vtk: Update to 9.4.1
Date: Mon, 24 Feb 2025 09:48:15 +0100
[Message part 1 (text/plain, inline)]
Dear Ludovic,

thanks for your comments. I have uploaded a patch for freecad, this one:

https://github.com/FreeCAD/FreeCAD/commit/fafff3a08b7a6212ce3417e08b18cb2fc8e7e868

I hope this is fine.

Sincerely,
Lars

On 18 Feb 2025, at 18:19, Ludovic Courtès wrote:

> Hi Lars,
>
> Lars Bilke <lars.bilke <at> ufz.de> skribis:
>
>> * gnu/packages/image-processing.scm (vtk): Update to 9.4.1.
>>
>> Change-Id: Ife39df610c4487683a5c8d72b60eb750530c1358
>
> Apparently this breaks at least freecad:
>
> --8<---------------cut here---------------start------------->8---
> cd /tmp/guix-build-freecad-1.0.0.drv-0/build/src/Mod/CAM && 
> /gnu/store/2lxfijiqqljxdxr2ppqqrn5czkh4r1rq-cmake-minimal-3.24.2/bin/cmake 
> -E copy 
> /tmp/guix-build-freecad-1.0.0.drv-0/source/src/Mod/CAM/Path/Op/Util.py 
> /tmp/guix-build-freecad-1.0.0.drv-0/build/Mod/CAM/Path/Op/Util.py
> /tmp/guix-build-freecad-1.0.0.drv-0/source/src/3rdParty/salomesmesh/src/SMDS/SMDS_UnstructuredGrid.cpp: 
> In member function ‘void SMDS_UnstructuredGrid::BuildLinks()’:
> /tmp/guix-build-freecad-1.0.0.drv-0/source/src/3rdParty/salomesmesh/src/SMDS/SMDS_UnstructuredGrid.cpp:1030:25: 
> error: no matching function for call to 
> ‘vtkCellLinks::BuildLinks(SMDS_UnstructuredGrid*)’
>  1030 |   GetLinks()->BuildLinks(this);
>       |   ~~~~~~~~~~~~~~~~~~~~~~^~~~~~
> In file included from 
> /tmp/guix-build-freecad-1.0.0.drv-0/source/src/3rdParty/salomesmesh/inc/SMDS_UnstructuredGrid.hxx:30,
>                  from 
> /tmp/guix-build-freecad-1.0.0.drv-0/source/src/3rdParty/salomesmesh/src/SMDS/SMDS_UnstructuredGrid.cpp:20:
> /gnu/store/gr8mwbl3zlx9hc4x9k5s9sgcy2kp4sr9-vtk-9.4.1/include/vtk-9.4/vtkCellLinks.h:64:8: 
> note: candidate: ‘virtual void vtkCellLinks::BuildLinks()’
>    64 |   void BuildLinks() override;
>       |        ^~~~~~~~~~
> /gnu/store/gr8mwbl3zlx9hc4x9k5s9sgcy2kp4sr9-vtk-9.4.1/include/vtk-9.4/vtkCellLinks.h:64:8: 
> note:   candidate expects 0 arguments, 1 provided
> --8<---------------cut here---------------end--------------->8---
>
> Could you take a look?  (Perhaps the solution will be to retain the
> previous version of VTK for use in packages like this one.)
>
> More generally, could you test with:
>
>   guix build -P1 vtk <at> 9.4.1 -P1 vtk <at> 7
>
> ?
>
> Dependent packages like ‘python-fenics-fiat’ are already broken, 
> so it’s
> “okay” to keep them broken.
>
> Thanks,
> Ludo’.
[Message part 2 (text/html, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#76269; Package guix-patches. (Thu, 27 Feb 2025 14:28:03 GMT) Full text and rfc822 format available.

Message #20 received at 76269 <at> debbugs.gnu.org (full text, mbox):

From: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
To: Lars Bilke <lars.bilke <at> ufz.de>
Cc: 76269 <at> debbugs.gnu.org, Cayetano Santos <csantosb <at> inventati.org>
Subject: Re: [bug#76269] [PATCH 2/2] gnu: freecad: Add vtk 9.4.1 patch.
Date: Thu, 27 Feb 2025 23:27:25 +0900
Hi Lars,

Lars Bilke <lars.bilke <at> ufz.de> writes:

> * gnu/packages/engineering.scm (freecad): Add vtk 9.4.1 patch.
> * gnu/local.mk: Add freecad vtk 9.4.1 patch to list.
>
> Change-Id: I9220aec757c2331a2dfa3eee9d0b84f774785de3
> ---
>  gnu/local.mk                              |  1 +
>  gnu/packages/engineering.scm              |  1 +
>  gnu/packages/patches/freecad-vtk941.patch | 71 +++++++++++++++++++++++
>  3 files changed, 73 insertions(+)
>  create mode 100644 gnu/packages/patches/freecad-vtk941.patch
>
> diff --git a/gnu/local.mk b/gnu/local.mk
> index 45a9cb635e..35e1b5e6b6 100644
> --- a/gnu/local.mk
> +++ b/gnu/local.mk
> @@ -1317,6 +1317,7 @@ dist_patch_DATA =						\
>    %D%/packages/patches/fpc-reproducibility.patch		\
>    %D%/packages/patches/fpc-glibc-2.34-compat.patch		\
>    %D%/packages/patches/fpm-newer-clamp-fix.patch		\
> +  %D%/packages/patches/freecad-vtk941.patch	\
>    %D%/packages/patches/freedict-tools-fix-determinism.patch	\
>    %D%/packages/patches/freedink-engine-fix-sdl-hints.patch	\
>    %D%/packages/patches/freeimage-libtiff-compat.patch		\
> diff --git a/gnu/packages/engineering.scm b/gnu/packages/engineering.scm
> index 234f4a2b03..d4d920cd08 100644
> --- a/gnu/packages/engineering.scm
> +++ b/gnu/packages/engineering.scm
> @@ -3173,6 +3173,7 @@ (define-public freecad
>         (file-name (git-file-name name version))
>         (sha256
>          (base32 "0wwymcfgi0cybj7m6awflk8c7n6iy97lpgpfhfncx3zwvjrxv588"))
> +       (patches (search-patches "freecad-vtk941.patch"))  ;; remove on 1.1 release

Thanks for the patch.  Is there a reason we cannot update our freecade
to 1.1 yet?  Perhaps it is not released?

Otherwise, LGTM.

Reviewed-by: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>

--
Thanks,
Maxim




Information forwarded to guix-patches <at> gnu.org:
bug#76269; Package guix-patches. (Thu, 27 Feb 2025 14:31:11 GMT) Full text and rfc822 format available.

Message #23 received at 76269 <at> debbugs.gnu.org (full text, mbox):

From: Lars Bilke <lars.bilke <at> ufz.de>
To: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
Cc: 76269 <at> debbugs.gnu.org, Cayetano Santos <csantosb <at> inventati.org>
Subject: Re: [bug#76269] [PATCH 2/2] gnu: freecad: Add vtk 9.4.1 patch.
Date: Thu, 27 Feb 2025 15:30:18 +0100
Dear Maxim,

thanks for your review.

FreeCAD 1.1 is not released yet.

Sincerely,
Lars

On 27 Feb 2025, at 15:27, Maxim Cournoyer wrote:
>
> Thanks for the patch.  Is there a reason we cannot update our freecade
> to 1.1 yet?  Perhaps it is not released?
>
> Otherwise, LGTM.
>
> Reviewed-by: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
>
> --
> Thanks,
> Maxim




Information forwarded to guix-patches <at> gnu.org:
bug#76269; Package guix-patches. (Thu, 27 Feb 2025 15:55:02 GMT) Full text and rfc822 format available.

Message #26 received at 76269 <at> debbugs.gnu.org (full text, mbox):

From: Lars Bilke <lars.bilke <at> ufz.de>
To: 76269 <at> debbugs.gnu.org
Cc: Lars Bilke <lars.bilke <at> ufz.de>
Subject: [PATCH 1/3] gnu: vtk: Update to 9.4.1
Date: Thu, 27 Feb 2025 16:54:09 +0100
* gnu/packages/image-processing.scm (vtk): Update to 9.4.1.

Change-Id: Ife39df610c4487683a5c8d72b60eb750530c1358
---
 gnu/packages/image-processing.scm | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/gnu/packages/image-processing.scm b/gnu/packages/image-processing.scm
index 405f90ca9a..a456d94863 100644
--- a/gnu/packages/image-processing.scm
+++ b/gnu/packages/image-processing.scm
@@ -323,7 +323,7 @@ (define-public opencolorio
 (define-public vtk
   (package
     (name "vtk")
-    (version "9.3.0")
+    (version "9.4.1")
     (source (origin
               (method url-fetch)
               (uri (string-append "https://vtk.org/files/release/"
@@ -331,7 +331,7 @@ (define-public vtk
                                   "/VTK-" version ".tar.gz"))
               (sha256
                (base32
-                "1s8vd34nhrgnw1bf9zhfn062d53fwq3csjfwvm7lxcr5a8lvkizx"))
+                "0aa5pkw2xxzksl48ldbj3cq6r4y4mxvcpl66f64gkah2s34b0ly2"))
               (modules '((guix build utils)))
               (snippet
                '(begin
@@ -341,7 +341,7 @@ (define-public vtk
                       (string-append "ThirdParty/" dir "/vtk" dir)))
                    ;; pugixml depended upon unconditionally
                    '("doubleconversion" "eigen" "expat" "freetype" "gl2ps"
-                     "glew" "hdf5" "jpeg" "jsoncpp" "libharu" "libproj"
+                     "hdf5" "jpeg" "jsoncpp" "libharu" "libproj"
                      "libxml2" "lz4" "netcdf" "ogg" "png" "sqlite" "theora"
                      "tiff" "zlib"))
                   (substitute* "IO/ExportPDF/vtkPDFContextDevice2D.cxx"
@@ -360,7 +360,6 @@ (define-public vtk
                "-DVTK_MODULE_USE_EXTERNAL_VTK_expat=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_freetype=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_gl2ps=ON"
-               "-DVTK_MODULE_USE_EXTERNAL_VTK_glew=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_hdf5=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_jpeg=ON"
                "-DVTK_MODULE_USE_EXTERNAL_VTK_jsoncpp=ON"
@@ -380,7 +379,7 @@ (define-public vtk
                "-DVTK_WRAP_PYTHON=ON"
                "-DVTK_PYTHON_VERSION:STRING=3"
 
-               "-DVTK_SMP_ENABLE_OPENNMP=ON"
+               "-DVTK_SMP_ENABLE_OPENMP=ON"
                "-DVTK_SMP_ENABLE_TBB=ON"
                "-DVTK_USE_MPI=ON"
                #$@(if (target-riscv64?)

base-commit: c4fcf8fb627c9ea54a4a639a81766e5df3973fdc
-- 
2.46.1





Information forwarded to csantosb <at> inventati.org, maxim.cournoyer <at> gmail.com, guix-patches <at> gnu.org:
bug#76269; Package guix-patches. (Thu, 27 Feb 2025 15:55:03 GMT) Full text and rfc822 format available.

Message #29 received at 76269 <at> debbugs.gnu.org (full text, mbox):

From: Lars Bilke <lars.bilke <at> ufz.de>
To: 76269 <at> debbugs.gnu.org
Cc: Lars Bilke <lars.bilke <at> ufz.de>
Subject: [PATCH 2/3] gnu: freecad: Add vtk 9.4.1 patch.
Date: Thu, 27 Feb 2025 16:54:10 +0100
* gnu/packages/engineering.scm (freecad): Add vtk 9.4.1 patch.
* gnu/local.mk: Add freecad vtk 9.4.1 patch to list.

Change-Id: I9220aec757c2331a2dfa3eee9d0b84f774785de3
---
 gnu/local.mk                              |  1 +
 gnu/packages/engineering.scm              |  1 +
 gnu/packages/patches/freecad-vtk941.patch | 71 +++++++++++++++++++++++
 3 files changed, 73 insertions(+)
 create mode 100644 gnu/packages/patches/freecad-vtk941.patch

diff --git a/gnu/local.mk b/gnu/local.mk
index 45a9cb635e..35e1b5e6b6 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1317,6 +1317,7 @@ dist_patch_DATA =						\
   %D%/packages/patches/fpc-reproducibility.patch		\
   %D%/packages/patches/fpc-glibc-2.34-compat.patch		\
   %D%/packages/patches/fpm-newer-clamp-fix.patch		\
+  %D%/packages/patches/freecad-vtk941.patch	\
   %D%/packages/patches/freedict-tools-fix-determinism.patch	\
   %D%/packages/patches/freedink-engine-fix-sdl-hints.patch	\
   %D%/packages/patches/freeimage-libtiff-compat.patch		\
diff --git a/gnu/packages/engineering.scm b/gnu/packages/engineering.scm
index 234f4a2b03..d4d920cd08 100644
--- a/gnu/packages/engineering.scm
+++ b/gnu/packages/engineering.scm
@@ -3173,6 +3173,7 @@ (define-public freecad
        (file-name (git-file-name name version))
        (sha256
         (base32 "0wwymcfgi0cybj7m6awflk8c7n6iy97lpgpfhfncx3zwvjrxv588"))
+       (patches (search-patches "freecad-vtk941.patch"))  ;; remove on 1.1 release
        (modules '((guix build utils)))
        (snippet
         '(begin
diff --git a/gnu/packages/patches/freecad-vtk941.patch b/gnu/packages/patches/freecad-vtk941.patch
new file mode 100644
index 0000000000..e05548a599
--- /dev/null
+++ b/gnu/packages/patches/freecad-vtk941.patch
@@ -0,0 +1,71 @@
+From fafff3a08b7a6212ce3417e08b18cb2fc8e7e868 Mon Sep 17 00:00:00 2001
+From: wmayer <wmayer <at> freecad.org>
+Date: Mon, 16 Dec 2024 10:56:43 +0100
+Subject: [PATCH] smesh: Fix build failure with vtk 9.4
+
+Fixes #18423
+---
+ .../src/SMDS/SMDS_UnstructuredGrid.cpp          | 17 ++++++++++-------
+ 1 file changed, 10 insertions(+), 7 deletions(-)
+
+diff --git a/src/3rdParty/salomesmesh/src/SMDS/SMDS_UnstructuredGrid.cpp b/src/3rdParty/salomesmesh/src/SMDS/SMDS_UnstructuredGrid.cpp
+index e9895d615717..4e9d6dc05764 100644
+--- a/src/3rdParty/salomesmesh/src/SMDS/SMDS_UnstructuredGrid.cpp
++++ b/src/3rdParty/salomesmesh/src/SMDS/SMDS_UnstructuredGrid.cpp
+@@ -32,6 +32,7 @@
+ #include <vtkDoubleArray.h>
+ #include <vtkIdTypeArray.h>
+ #include <vtkUnsignedCharArray.h>
++#include <vtkVersionMacros.h>
+ 
+ #include <list>
+ #include <climits>
+@@ -249,14 +250,16 @@ void SMDS_UnstructuredGrid::compactGrid(std::vector<int>& idNodesOldToNew, int n
+     }
+   }
+ 
+-  if (this->FaceLocations)
++  vtkIdTypeArray* thisFaceLocations = GetFaceLocations();
++  vtkIdTypeArray* thisFaces = GetFaces();
++  if (thisFaceLocations)
+     {
+       vtkIdTypeArray *newFaceLocations = vtkIdTypeArray::New();
+       newFaceLocations->Initialize();
+       newFaceLocations->Allocate(newTypes->GetSize());
+       vtkIdTypeArray *newFaces = vtkIdTypeArray::New();
+       newFaces->Initialize();
+-      newFaces->Allocate(this->Faces->GetSize());
++      newFaces->Allocate(thisFaces->GetSize());
+       for (int i = 0; i < oldCellSize; i++)
+         {
+           if (this->Types->GetValue(i) == VTK_EMPTY_CELL)
+@@ -265,16 +268,16 @@ void SMDS_UnstructuredGrid::compactGrid(std::vector<int>& idNodesOldToNew, int n
+           if (newTypes->GetValue(newCellId) == VTK_POLYHEDRON)
+             {
+                newFaceLocations->InsertNextValue(newFaces->GetMaxId()+1);
+-               int oldFaceLoc = this->FaceLocations->GetValue(i);
+-               int nCellFaces = this->Faces->GetValue(oldFaceLoc++);
++               int oldFaceLoc = thisFaceLocations->GetValue(i);
++               int nCellFaces = thisFaces->GetValue(oldFaceLoc++);
+                newFaces->InsertNextValue(nCellFaces);
+                for (int n=0; n<nCellFaces; n++)
+                  {
+-                   int nptsInFace = this->Faces->GetValue(oldFaceLoc++);
++                   int nptsInFace = thisFaces->GetValue(oldFaceLoc++);
+                    newFaces->InsertNextValue(nptsInFace);
+                    for (int k=0; k<nptsInFace; k++)
+                      {
+-                       int oldpt = this->Faces->GetValue(oldFaceLoc++);
++                       int oldpt = thisFaces->GetValue(oldFaceLoc++);
+                        newFaces->InsertNextValue(idNodesOldToNew[oldpt]);
+                      }
+                  }
+@@ -292,7 +295,7 @@ void SMDS_UnstructuredGrid::compactGrid(std::vector<int>& idNodesOldToNew, int n
+     }
+   else
+   {
+-    this->SetCells(newTypes, newLocations, newConnectivity, FaceLocations, Faces);
++    this->SetCells(newTypes, newLocations, newConnectivity, thisFaceLocations, thisFaces);
+   }
+ 
+   newPoints->Delete();
\ No newline at end of file
-- 
2.46.1





Information forwarded to guix-patches <at> gnu.org:
bug#76269; Package guix-patches. (Thu, 27 Feb 2025 15:55:04 GMT) Full text and rfc822 format available.

Message #32 received at 76269 <at> debbugs.gnu.org (full text, mbox):

From: Lars Bilke <lars.bilke <at> ufz.de>
To: 76269 <at> debbugs.gnu.org
Cc: Lars Bilke <lars.bilke <at> ufz.de>
Subject: [PATCH 3/3] gnu: vtk: Fix OpenCV build.
Date: Thu, 27 Feb 2025 16:54:11 +0100
* gnu/packages/image-processing.scm (vtk): Add jsoncpp to
  propagated-inputs. This fixes the OpenCV configuration step.

Change-Id: I863079394a4345cc5f0a8e67fe19831070f16d09
---
 gnu/packages/image-processing.scm | 1 +
 1 file changed, 1 insertion(+)

diff --git a/gnu/packages/image-processing.scm b/gnu/packages/image-processing.scm
index a456d94863..fed26291e5 100644
--- a/gnu/packages/image-processing.scm
+++ b/gnu/packages/image-processing.scm
@@ -440,6 +440,7 @@ (define-public vtk
      ;; 'find_package(THEORA)', which in turns looks for libogg.  Likewise for
      ;; TBB.
      (list libogg
+           jsoncpp ; fixes OpenCVs configure not finding JsonCpp::JsonCpp target
            tbb))
     (home-page "https://vtk.org/")
     (synopsis "Libraries for 3D computer graphics")
-- 
2.46.1





Information forwarded to guix-patches <at> gnu.org:
bug#76269; Package guix-patches. (Thu, 27 Feb 2025 16:27:02 GMT) Full text and rfc822 format available.

Message #35 received at 76269 <at> debbugs.gnu.org (full text, mbox):

From: Cayetano Santos <csantosb <at> inventati.org>
To: lars.bilke <at> ufz.de
Cc: 76269 <at> debbugs.gnu.org
Subject: Re: [bug#76269] [PATCH 1/3] gnu: vtk: Update to 9.4.1
Date: Thu, 27 Feb 2025 17:26:35 +0100
[Message part 1 (text/plain, inline)]
With your patch, I manage to build and run vtk and freecad.

A couple of comments:

- better send patches as [PATCH v2 1/3], etc. (hard to follow otherwise)
- use guix style/lint to check the patches before sending

There are lots of dependent packages still to build, see

   https://qa.guix.gnu.org/issue/76269
[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#76269; Package guix-patches. (Fri, 28 Feb 2025 02:17:01 GMT) Full text and rfc822 format available.

Message #38 received at 76269 <at> debbugs.gnu.org (full text, mbox):

From: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
To: Cayetano Santos <csantosb <at> inventati.org>
Cc: 76269 <at> debbugs.gnu.org, lars.bilke <at> ufz.de
Subject: [bug#76269] [PATCH 1/3] gnu: vtk: Update to 9.4.1
Date: Fri, 28 Feb 2025 11:15:45 +0900
Hi,

Cayetano Santos <csantosb <at> inventati.org> writes:

> With your patch, I manage to build and run vtk and freecad.
>
> A couple of comments:
>
> - better send patches as [PATCH v2 1/3], etc. (hard to follow otherwise)
> - use guix style/lint to check the patches before sending
>
> There are lots of dependent packages still to build, see
>
>    https://qa.guix.gnu.org/issue/76269

Good call, let's give this some extra time.

-- 
Thanks,
Maxim




Information forwarded to guix-patches <at> gnu.org:
bug#76269; Package guix-patches. (Fri, 28 Feb 2025 08:06:02 GMT) Full text and rfc822 format available.

Message #41 received at 76269 <at> debbugs.gnu.org (full text, mbox):

From: Cayetano Santos <csantosb <at> inventati.org>
To: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
Cc: 76269 <at> debbugs.gnu.org, lars.bilke <at> ufz.de
Subject: Re: [bug#76269] [PATCH 1/3] gnu: vtk: Update to 9.4.1
Date: Fri, 28 Feb 2025 09:05:47 +0100
[Message part 1 (text/plain, inline)]
>ven. 28 févr. 2025 at 11:15, Maxim Cournoyer <maxim.cournoyer <at> gmail.com> wrote:

>> There are lots of dependent packages still to build, see
>>
>>    https://qa.guix.gnu.org/issue/76269
>
> Good call, let's give this some extra time.

One of the tests of OpenCV fails now with the latest patch set:

    https://data.qa.guix.gnu.org/gnu/store/kbmx3vlin6h8jclqchmv7y5px4ysz818-opencv-4.11.0.drv
[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#76269; Package guix-patches. (Sun, 02 Mar 2025 01:36:01 GMT) Full text and rfc822 format available.

Message #44 received at 76269 <at> debbugs.gnu.org (full text, mbox):

From: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
To: Lars Bilke <lars.bilke <at> ufz.de>
Cc: 76269 <at> debbugs.gnu.org, Cayetano Santos <csantosb <at> inventati.org>
Subject: [bug#76269] [PATCH 1/3] gnu: vtk: Update to 9.4.1
Date: Sun, 02 Mar 2025 10:35:31 +0900
Hi Lars,

Cayetano Santos <csantosb <at> inventati.org> writes:

>>ven. 28 févr. 2025 at 11:15, Maxim Cournoyer <maxim.cournoyer <at> gmail.com> wrote:
>
>>> There are lots of dependent packages still to build, see
>>>
>>>    https://qa.guix.gnu.org/issue/76269
>>
>> Good call, let's give this some extra time.
>
> One of the tests of OpenCV fails now with the latest patch set:
>
>     https://data.qa.guix.gnu.org/gnu/store/kbmx3vlin6h8jclqchmv7y5px4ysz818-opencv-4.11.0.drv

Could you please take a look?

The error is a segfault in the opencv_test_viz test:

--8<---------------cut here---------------start------------->8---
12/45 Test #12: opencv_test_viz ...................***Exception: SegFault  0.06 sec
--8<---------------cut here---------------end--------------->8---

See: https://bordeaux.guix.gnu.org/build/d9a59eed-08db-4916-b740-922b92120b02/log

-- 
Thanks,
Maxim




This bug report was last modified 111 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.