]> SALOME platform Git repositories - tools/sat_salome.git/commitdiff
Salome HOME
Porting to OCCT 7.8.0
authorjfa <jfa@opencascade.com>
Wed, 31 Jan 2024 16:07:21 +0000 (16:07 +0000)
committerjfa <jfa@opencascade.com>
Wed, 31 Jan 2024 16:07:21 +0000 (16:07 +0000)
applications/SALOME-master-native.pyconf
products/gmsh.pyconf
products/netgen.pyconf
products/patches/gmsh-4.10.3-occt780.patch [new file with mode: 0644]
products/patches/netgen5.3_withOCCT780_linux.patch [new file with mode: 0644]
products/patches/netgen5.3_withOCCT780_win.patch [new file with mode: 0644]

index c39c73e22757c2f7519eba1f6d92ad652a5fb89e..cd29a0f683710258f04ef95971998184241833fc 100644 (file)
@@ -61,7 +61,7 @@ APPLICATION :
         freetype : 'native'
         gl2ps : 'native'
         gdal : 'native'
-        gmsh : '4.10.3'
+        gmsh : '4.10.3_with_CAS_7.8'
         graphviz : 'native'
         hdf5 : '1.10.3'
         idna : 'native'
@@ -79,7 +79,7 @@ APPLICATION :
         MeshGems : '2.15-1'
         metis : 'native'
         mpi4py: 'native'
-        netgen : '5.3.1_with_CAS_7.2'
+        netgen : '5.3.1_with_CAS_7.8'
         # comment out line above and uncomment the line below to use Netgen 6.
         #netgen : '6.2.2101'
         netcdf : 'native'
index 8b18cdcd56af5d2038b896e7bb20b42c555e1cb7..9614ac73e18e6a809002ce5b198fbde2eb72f7b1 100644 (file)
@@ -31,6 +31,14 @@ default_win:
     }
 }
 
+version_4_10_3_with_CAS_7_8:
+{
+  archive_info : {archive_name : "gmsh-4.10.3.tar.gz"}
+  compil_script : "gmsh-4.10.3.sh"
+  depend : ["CAS","lapack","hdf5","medfile", "cgns"]
+  patches : ['gmsh-4.10.3-occt780.patch']
+}
+
 version_4_10_3:
 {
   compil_script : "gmsh-4.10.3.sh"
index 05e01d166e7a9918306d19c81421041c0a477fff..7d567ac26a27c97b7936290a681b4f4999385e6a 100644 (file)
@@ -52,6 +52,24 @@ version_6_2_2101_win :
    }
 }
 
+version_5_3_1_with_CAS_7_8 :
+{
+    archive_info : {archive_name : "netgen-5.3.1.tar.gz"}
+    compil_script :  'netgen_5_3_1' + $VARS.scriptExtension
+    patches : ["netgen-5.3.1-for-SALOME-OCCT-7.2.0.patch","netgen5.3_withOCCT780_linux.patch"]
+}
+
+version_5_3_1_with_CAS_7_8_win :
+{
+   compil_script :  'netgen.bat'
+   patches :  ['netgen53ForSalomeOCCT730.patch','netgen53ForWindows.patch','netgen53ForSalomeVisualStudio2017.patch','netgen5.3_withOCCT780_win.patch']
+   properties :
+   {
+     incremental : "yes"
+     single_install_dir : "yes"
+   }
+}
+
 version_5_3_1_with_CAS_7_2 :
 {
     archive_info : {archive_name : "netgen-5.3.1.tar.gz"}
diff --git a/products/patches/gmsh-4.10.3-occt780.patch b/products/patches/gmsh-4.10.3-occt780.patch
new file mode 100644 (file)
index 0000000..ea95587
--- /dev/null
@@ -0,0 +1,22 @@
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 8f99dfe..8955a1f 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -1264,7 +1264,7 @@ if(ENABLE_OCC)
+   elseif(OCC_INC)
+     set(OCC_LIBS_REQUIRED
+       # subset of DataExchange
+-              TKSTEP TKSTEP209 TKSTEPAttr TKSTEPBase TKIGES TKXSBase
++              TKDESTEP TKDEIGES TKXSBase
+               # ModelingAlgorithms
+               TKOffset TKFeat TKFillet TKBool TKMesh TKHLR TKBO TKPrim TKShHealing
+               TKTopAlgo TKGeomAlgo
+@@ -1304,7 +1304,7 @@ if(ENABLE_OCC)
+     find_package(Freetype)
+     if(FREETYPE_FOUND)
+       set(OCC_CAF_LIBS_REQUIRED
+-          TKXDESTEP TKXDEIGES TKXCAF TKLCAF TKVCAF TKCAF TKV3d TKService TKCDF)
++          TKXCAF TKLCAF TKVCAF TKCAF TKV3d TKService TKCDF)
+       list(LENGTH OCC_CAF_LIBS_REQUIRED NUM_OCC_CAF_LIBS_REQUIRED)
+       set(OCC_CAF_LIBS)
+       foreach(OCC ${OCC_CAF_LIBS_REQUIRED})
diff --git a/products/patches/netgen5.3_withOCCT780_linux.patch b/products/patches/netgen5.3_withOCCT780_linux.patch
new file mode 100644 (file)
index 0000000..001981e
--- /dev/null
@@ -0,0 +1,70 @@
+diff --git a/configure.ac b/configure.ac
+index 6db9de0..1c597c9 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -43,7 +43,7 @@ AC_ARG_WITH([occ],
+ if test a$occon = atrue ; then
+       AC_SUBST([OCCFLAGS], ["-DOCCGEOMETRY -I$occdir/include/opencascade"])
+-      AC_SUBST([OCCLIBS], ["-L$occdir/lib -lTKernel -lTKGeomBase -lTKMath -lTKG2d -lTKG3d -lTKXSBase -lTKOffset -lTKFillet -lTKShHealing -lTKMesh -lTKMeshVS -lTKTopAlgo -lTKGeomAlgo -lTKBool -lTKPrim -lTKBO -lTKIGES -lTKBRep -lTKSTEPBase -lTKSTEP -lTKSTL -lTKSTEPAttr -lTKSTEP209 -lTKXDESTEP -lTKXDEIGES -lTKXCAF -lTKLCAF"])
++      AC_SUBST([OCCLIBS], ["-L$occdir/lib -lTKernel -lTKGeomBase -lTKMath -lTKG2d -lTKG3d -lTKXSBase -lTKOffset -lTKFillet -lTKShHealing -lTKMesh -lTKMeshVS -lTKTopAlgo -lTKGeomAlgo -lTKBool -lTKPrim -lTKBO -lTKBRep -lTKXCAF -lTKLCAF -lTKDEIGES -lTKDESTEP -lTKDESTL"])
+ #  -lTKDCAF
+diff --git a/libsrc/occ/occgenmesh.cpp b/libsrc/occ/occgenmesh.cpp
+index 5026536..8074ca6 100644
+--- a/libsrc/occ/occgenmesh.cpp
++++ b/libsrc/occ/occgenmesh.cpp
+@@ -1242,9 +1242,9 @@ namespace netgen
\r
+                for (int k = 1; k <=3; k++)\r
+                {\r
+-                  int n = triangulation->Triangles()(j)(k);\r
+-                  p[k-1] = triangulation->Nodes()(n).Transformed(loc);\r
+-                  par[k-1] = triangulation->UVNodes()(n);\r
++                  int n = triangulation->Triangle(j)(k);\r
++                  p[k - 1] = triangulation->Node(n).Transformed(loc);\r
++                  par[k - 1] = triangulation->UVNode(n);\r
+                }\r
\r
+                //double maxside = 0;\r
+diff --git a/libsrc/occ/vsocc.cpp b/libsrc/occ/vsocc.cpp
+index 4d80600..74a85ae 100644
+--- a/libsrc/occ/vsocc.cpp
++++ b/libsrc/occ/vsocc.cpp
+@@ -463,7 +463,7 @@ namespace netgen
+          glBegin (GL_LINE_STRIP);
+          for (int j = 1; j <= nbnodes; j++)
+          {
+-            gp_Pnt p = (T -> Nodes())(aEdgePoly->Nodes()(j)).Transformed(aEdgeLoc);
++            gp_Pnt p = T -> Node(aEdgePoly->Nodes()(j)).Transformed(aEdgeLoc);
+             glVertex3f (p.X(), p.Y(), p.Z());
+          }
+          glEnd ();
+@@ -510,7 +510,7 @@ namespace netgen
+          glBegin (GL_LINE_STRIP);
+          for (int j = 1; j <= nbnodes; j++)
+          {
+-            gp_Pnt p = (T -> Nodes())(aEdgePoly->Nodes()(j)).Transformed(aEdgeLoc);
++            gp_Pnt p = T -> Node(aEdgePoly->Nodes()(j)).Transformed(aEdgeLoc);
+             glVertex3f (p.X(), p.Y(), p.Z());
+          }
+          glEnd ();
+@@ -586,14 +586,14 @@ namespace netgen
+          int ntriangles = triangulation -> NbTriangles();
+          for (int j = 1; j <= ntriangles; j++)
+          {
+-            Poly_Triangle triangle = (triangulation -> Triangles())(j);
++            Poly_Triangle triangle = triangulation -> Triangle(j);
+             gp_Pnt p[3];
+             for (int k = 1; k <= 3; k++)
+-            p[k-1] = (triangulation -> Nodes())(triangle(k)).Transformed(loc);
++            p[k-1] = triangulation -> Node(triangle(k)).Transformed(loc);
+             for (int k = 1; k <= 3; k++)
+             {
+-               uv = (triangulation -> UVNodes())(triangle(k));
++               uv = triangulation -> UVNode(triangle(k));
+                prop.SetParameters (uv.X(), uv.Y());
+                //           surf->D0 (uv.X(), uv.Y(), pnt);
diff --git a/products/patches/netgen5.3_withOCCT780_win.patch b/products/patches/netgen5.3_withOCCT780_win.patch
new file mode 100644 (file)
index 0000000..ad10387
--- /dev/null
@@ -0,0 +1,61 @@
+ libsrc/occ/occgenmesh.cpp |  6 +++---
+ libsrc/occ/vsocc.cpp      | 10 +++++-----
+ 2 files changed, 8 insertions(+), 8 deletions(-)
+
+diff --git a/libsrc/occ/occgenmesh.cpp b/libsrc/occ/occgenmesh.cpp
+index 1e0127f..d9b4e6f 100644
+--- a/libsrc/occ/occgenmesh.cpp
++++ b/libsrc/occ/occgenmesh.cpp
+@@ -1242,9 +1242,9 @@ namespace netgen
+                for (int k = 1; k <=3; k++)
+                {
+-                  int n = triangulation->Triangles()(j)(k);
+-                  p[k-1] = triangulation->Nodes()(n).Transformed(loc);
+-                  par[k-1] = triangulation->UVNodes()(n);
++                  int n = triangulation->Triangle(j)(k);
++                  p[k - 1] = triangulation->Node(n).Transformed(loc);
++                  par[k - 1] = triangulation->UVNode(n);
+                }
+                //double maxside = 0;
+diff --git a/libsrc/occ/vsocc.cpp b/libsrc/occ/vsocc.cpp
+index 4d80600..0070b56 100644
+--- a/libsrc/occ/vsocc.cpp
++++ b/libsrc/occ/vsocc.cpp
+@@ -463,7 +463,7 @@ namespace netgen
+          glBegin (GL_LINE_STRIP);
+          for (int j = 1; j <= nbnodes; j++)
+          {
+-            gp_Pnt p = (T -> Nodes())(aEdgePoly->Nodes()(j)).Transformed(aEdgeLoc);
++            gp_Pnt p = T->Node(aEdgePoly->Nodes()(j)).Transformed(aEdgeLoc);
+             glVertex3f (p.X(), p.Y(), p.Z());
+          }
+          glEnd ();
+@@ -510,7 +510,7 @@ namespace netgen
+          glBegin (GL_LINE_STRIP);
+          for (int j = 1; j <= nbnodes; j++)
+          {
+-            gp_Pnt p = (T -> Nodes())(aEdgePoly->Nodes()(j)).Transformed(aEdgeLoc);
++            gp_Pnt p = T->Node(aEdgePoly->Nodes()(j)).Transformed(aEdgeLoc);
+             glVertex3f (p.X(), p.Y(), p.Z());
+          }
+          glEnd ();
+@@ -586,14 +586,14 @@ namespace netgen
+          int ntriangles = triangulation -> NbTriangles();
+          for (int j = 1; j <= ntriangles; j++)
+          {
+-            Poly_Triangle triangle = (triangulation -> Triangles())(j);
++            Poly_Triangle triangle = triangulation->Triangles(j);
+             gp_Pnt p[3];
+             for (int k = 1; k <= 3; k++)
+-            p[k-1] = (triangulation -> Nodes())(triangle(k)).Transformed(loc);
++            p[k-1] = triangulation -> Nodes(triangle(k)).Transformed(loc);
+             for (int k = 1; k <= 3; k++)
+             {
+-               uv = (triangulation -> UVNodes())(triangle(k));
++               uv = triangulation -> UVNodes(triangle(k));
+                prop.SetParameters (uv.X(), uv.Y());
+                //           surf->D0 (uv.X(), uv.Y(), pnt);