Compile on Linux with gcc-c++ 8.0.1

Having trouble installing or compiling FreeCAD? Get help here.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
mdhill
Posts: 85
Joined: Mon Apr 24, 2017 7:37 pm

Compile on Linux with gcc-c++ 8.0.1

Post by mdhill »

I asked this question a couple of weeks ago but may have mislabelled it. My distro happens to be Fedora, but it's not necessarily distro-specific. The build fails (below) at std::set compare, as in this bug:

https://bugzilla.redhat.com/show_bug.cgi?id=1541688

Code: Select all

In file included from /usr/include/c++/8/map:60,
                 from /home/mike/free-cad-code/src/3rdParty/salomesmesh/inc/SMESH_Algo.hxx:45,
                 from /home/mike/free-cad-code/src/3rdParty/salomesmesh/inc/StdMeshers_Projection_2D.hxx:32,
                 from /home/mike/free-cad-code/src/3rdParty/salomesmesh/inc/StdMeshers_Projection_1D2D.hxx:29,
                 from /home/mike/free-cad-code/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_Projection_1D2D.cpp:26:
/usr/include/c++/8/bits/stl_tree.h: In instantiation of ‘class std::_Rb_tree<const SMDS_MeshNode*, const SMDS_MeshNode*, std::_Identity<const SMDS_MeshNode*>, TIDCompare, std::allocator<const SMDS_MeshNode*> >’:
/usr/include/c++/8/bits/stl_set.h:133:17:   required from ‘class std::set<const SMDS_MeshNode*, TIDCompare>’
/home/mike/free-cad-code/src/3rdParty/salomesmesh/inc/SMESH_MesherHelper.hxx:716:24:   required from here
/usr/include/c++/8/bits/stl_tree.h:452:21: error: static assertion failed: comparison object must be invocable with two arguments of key type
       static_assert(__is_invocable<_Compare&, const _Key&, const _Key&>{},
                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
make[2]: *** [src/3rdParty/salomesmesh/CMakeFiles/StdMeshers.dir/build.make:999: src/3rdParty/salomesmesh/CMakeFiles/StdMeshers.dir/src/StdMeshers/StdMeshers_Projection_1D2D.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:468: src/3rdParty/salomesmesh/CMakeFiles/StdMeshers.dir/all] Error 2
make: *** [Makefile:130: all] Error 2
Has anyone else seen this?

Mike
mdhill
Posts: 85
Joined: Mon Apr 24, 2017 7:37 pm

Re: Compile on Linux with gcc-c++ 8.0.1

Post by mdhill »

Alternatively, is there an easy way to disable the compilation of the 3rdParty module where it errors out, or would that cause bigger problems?

Mike
wmayer
Founder
Posts: 20317
Joined: Thu Feb 19, 2009 10:32 am
Contact:

Re: Compile on Linux with gcc-c++ 8.0.1

Post by wmayer »

Does it work to add the switch "BUILD_SMESH" in cmake and setting it to OFF or 0?
mdhill
Posts: 85
Joined: Mon Apr 24, 2017 7:37 pm

Re: Compile on Linux with gcc-c++ 8.0.1

Post by mdhill »

-DBUILD_SMESH=0 or _DBUILD_SMESH=OFF don't seem to have an effect. Is there another way to add a switch?

Thanks,

Mike
ezzieyguywuf
Posts: 656
Joined: Tue May 19, 2015 1:11 am

Re: Compile on Linux with gcc-c++ 8.0.1

Post by ezzieyguywuf »

The latest version of gcc I see on the official website is 7.3. Are you using some kind of development build? What does "gcc --version" output in your terminal?
mdhill
Posts: 85
Joined: Mon Apr 24, 2017 7:37 pm

Re: Compile on Linux with gcc-c++ 8.0.1

Post by mdhill »

I'm living in the future with Fedora Rawhide. Building from git (and running) wasn't a problem until the gcc upgrade. Now I need to downgrade a number of packages to run my last good build, and przemof's latest Rawhide build is out of the question.

Code: Select all

$ gcc --version
gcc (GCC) 8.0.1 20180317 (Red Hat 8.0.1-0.19)
ezzieyguywuf
Posts: 656
Joined: Tue May 19, 2015 1:11 am

Re: Compile on Linux with gcc-c++ 8.0.1

Post by ezzieyguywuf »

mdhill wrote: Mon Mar 26, 2018 11:43 am I'm living in the future with Fedora Rawhide.
Hm. While I generally see no problem with wanting to run bleeding-edge software (I run gentoo, which typically means I'm running most of the latest stuff) for something as critical as GCC I'd stick to the latest release from upstream. v8.x appears to be something that is still in "trunk".

I realize you think your issues are non GCC related, but they very well could be.

On gentoo, we have a helper utility called "gcc-config" that allows us to have multiple versions of GCC installed and select which one to use. Do you have something similar on Fedora Rawhide? If so,can you switch to GCC 7.3 and see if the problem goes away?
mdhill
Posts: 85
Joined: Mon Apr 24, 2017 7:37 pm

Re: Compile on Linux with gcc-c++ 8.0.1

Post by mdhill »

ezzieyguywuf wrote: Mon Mar 26, 2018 1:53 pm On gentoo, we have a helper utility called "gcc-config" that allows us to have multiple versions of GCC installed and select which one to use. Do you have something similar on Fedora Rawhide? If so,can you switch to GCC 7.3 and see if the problem goes away?
I'll investigate the possibility. That would be ideal.

Meanwhile...
mdhill
Posts: 85
Joined: Mon Apr 24, 2017 7:37 pm

Re: Compile on Linux with gcc-c++ 8.0.1

Post by mdhill »

I deleted my build directory and started from scratch (as I did last week with no difference in the failure). This time I got a different error which yielded one Google hit:

https://forum.freecadweb.org/viewtopic.php?f=10&t=16229

From PrzemoF's cmake switches, I added '-DFREECAD_USE_EXTERNAL_SMESH=TRUE' and got to 60% before this failure:

Code: Select all

In file included from /usr/lib64/oce-0.18/../../include/oce/NCollection_EBTree.hxx:23,
                 from /usr/lib64/oce-0.18/../../include/oce/BRepMesh.hxx:34,
                 from /usr/lib64/oce-0.18/../../include/oce/BRepMesh_VertexInspector.hxx:22,
                 from /usr/lib64/oce-0.18/../../include/oce/BRepMesh_VertexTool.hxx:20,
                 from /usr/lib64/oce-0.18/../../include/oce/BRepMesh_DataStructureOfDelaun.hxx:19,
                 from /usr/lib64/oce-0.18/../../include/oce/BRepMesh_FastDiscret.hxx:20,
                 from /usr/lib64/oce-0.18/../../include/oce/BRepMesh_IncrementalMesh.hxx:20,
                 from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:35:
/usr/lib64/oce-0.18/../../include/oce/TCollection_Sequence.lxx: In copy constructor ‘TColStd_SequenceOfInteger::TColStd_SequenceOfInteger(const TColStd_SequenceOfInteger&)’:
/usr/lib64/oce-0.18/../../include/oce/TColStd_SequenceOfInteger.hxx:108:30: warning: base class ‘class TCollection_BaseSequence’ should be explicitly initialized in the copy constructor [-Wextra]
 #define TCollection_Sequence TColStd_SequenceOfInteger
                              ^~~~~~~~~~~~~~~~~~~~~~~~~
/usr/lib64/oce-0.18/../../include/oce/TColStd_SequenceOfInteger.hxx:108:30: note: in definition of macro ‘TCollection_Sequence’
 #define TCollection_Sequence TColStd_SequenceOfInteger
                              ^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/lib64/oce-0.18/../../include/oce/GCPnts_TangentialDeflection.hxx:15,
                 from /usr/lib64/oce-0.18/../../include/oce/BRepMesh_GeomTool.hxx:20,
                 from /usr/lib64/oce-0.18/../../include/oce/BRepMesh_Delaun.hxx:28,
                 from /usr/lib64/oce-0.18/../../include/oce/BRepMesh_FastDiscret.hxx:29,
                 from /usr/lib64/oce-0.18/../../include/oce/BRepMesh_IncrementalMesh.hxx:20,
                 from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:35:
/usr/lib64/oce-0.18/../../include/oce/TCollection_Sequence.lxx: In copy constructor ‘TColgp_SequenceOfPnt::TColgp_SequenceOfPnt(const TColgp_SequenceOfPnt&)’:
/usr/lib64/oce-0.18/../../include/oce/TColgp_SequenceOfPnt.hxx:109:30: warning: base class ‘class TCollection_BaseSequence’ should be explicitly initialized in the copy constructor [-Wextra]
 #define TCollection_Sequence TColgp_SequenceOfPnt
                              ^~~~~~~~~~~~~~~~~~~~
/usr/lib64/oce-0.18/../../include/oce/TColgp_SequenceOfPnt.hxx:109:30: note: in definition of macro ‘TCollection_Sequence’
 #define TCollection_Sequence TColgp_SequenceOfPnt
                              ^~~~~~~~~~~~~~~~~~~~
In file included from /usr/lib64/oce-0.18/../../include/oce/GCPnts_TangentialDeflection.hxx:16,
                 from /usr/lib64/oce-0.18/../../include/oce/BRepMesh_GeomTool.hxx:20,
                 from /usr/lib64/oce-0.18/../../include/oce/BRepMesh_Delaun.hxx:28,
                 from /usr/lib64/oce-0.18/../../include/oce/BRepMesh_FastDiscret.hxx:29,
                 from /usr/lib64/oce-0.18/../../include/oce/BRepMesh_IncrementalMesh.hxx:20,
                 from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:35:
/usr/lib64/oce-0.18/../../include/oce/TCollection_Sequence.lxx: In copy constructor ‘TColStd_SequenceOfReal::TColStd_SequenceOfReal(const TColStd_SequenceOfReal&)’:
/usr/lib64/oce-0.18/../../include/oce/TColStd_SequenceOfReal.hxx:109:30: warning: base class ‘class TCollection_BaseSequence’ should be explicitly initialized in the copy constructor [-Wextra]
 #define TCollection_Sequence TColStd_SequenceOfReal
                              ^~~~~~~~~~~~~~~~~~~~~~
/usr/lib64/oce-0.18/../../include/oce/TColStd_SequenceOfReal.hxx:109:30: note: in definition of macro ‘TCollection_Sequence’
 #define TCollection_Sequence TColStd_SequenceOfReal
                              ^~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/smesh/SMESHDS_Mesh.hxx:31,
                 from /usr/include/smesh/SMESH_subMesh.hxx:32,
                 from /usr/include/smesh/SMESH_2D_Algo.hxx:34,
                 from /usr/include/smesh/SMESH_Gen.hxx:40,
                 from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:43:
/usr/include/smesh/SMDS_Mesh.hxx: At global scope:
/usr/include/smesh/SMDS_Mesh.hxx:501:55: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   static int CheckMemory(const bool doNotRaise=false) throw (std::bad_alloc);
                                                       ^~~~~
In file included from /usr/include/smesh/SMESH_Gen.hxx:42,
                 from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:43:
/usr/include/smesh/SMESH_Mesh.hxx:113:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw(SALOME_Exception);
     ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:117:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw(SALOME_Exception);
     ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:121:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw(SALOME_Exception);
     ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:133:48: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   const std::list<SMESHDS_Command*> & GetLog() throw(SALOME_Exception);
                                                ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:135:19: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   void ClearLog() throw(SALOME_Exception);
                   ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:144:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw(SALOME_Exception);
     ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:147:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw(SALOME_Exception);
     ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:150:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw(SALOME_Exception);
     ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:155:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw(SALOME_Exception);
     ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:162:57: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   GetSubMeshUsingHypothesis(SMESHDS_Hypothesis * anHyp) throw(SALOME_Exception);
                                                         ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:180:40: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   void SetAutoColor(bool theAutoColor) throw(SALOME_Exception);
                                        ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:182:23: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   bool GetAutoColor() throw(SALOME_Exception);
                       ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:199:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw(SALOME_Exception);
     ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:201:36: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   void ExportDAT(const char *file) throw(SALOME_Exception);
                                    ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:202:36: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   void ExportUNV(const char *file) throw(SALOME_Exception);
                                    ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:203:56: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   void ExportSTL(const char *file, const bool isascii) throw(SALOME_Exception);
                                                        ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:205:17: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   int NbNodes() throw(SALOME_Exception);
                 ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:207:22: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   int Nb0DElements() throw(SALOME_Exception);
                      ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:209:55: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   int NbEdges(SMDSAbs_ElementOrder order = ORDER_ANY) throw(SALOME_Exception);
                                                       ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:211:55: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   int NbFaces(SMDSAbs_ElementOrder order = ORDER_ANY) throw(SALOME_Exception);
                                                       ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:213:59: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   int NbTriangles(SMDSAbs_ElementOrder order = ORDER_ANY) throw(SALOME_Exception);
                                                           ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:215:61: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   int NbQuadrangles(SMDSAbs_ElementOrder order = ORDER_ANY) throw(SALOME_Exception);
                                                             ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:217:20: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   int NbPolygons() throw(SALOME_Exception);
                    ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:219:57: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   int NbVolumes(SMDSAbs_ElementOrder order = ORDER_ANY) throw(SALOME_Exception);
                                                         ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:221:56: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   int NbTetras(SMDSAbs_ElementOrder order = ORDER_ANY) throw(SALOME_Exception);
                                                        ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:223:55: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   int NbHexas(SMDSAbs_ElementOrder order = ORDER_ANY) throw(SALOME_Exception);
                                                       ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:225:58: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   int NbPyramids(SMDSAbs_ElementOrder order = ORDER_ANY) throw(SALOME_Exception);
                                                          ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:227:56: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   int NbPrisms(SMDSAbs_ElementOrder order = ORDER_ANY) throw(SALOME_Exception);
                                                        ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:229:23: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   int NbPolyhedrons() throw(SALOME_Exception);
                       ^~~~~
/usr/include/smesh/SMESH_Mesh.hxx:231:19: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   int NbSubMesh() throw(SALOME_Exception);
                   ^~~~~
In file included from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:43:
/usr/include/smesh/SMESH_Gen.hxx:69:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw(SALOME_Exception);
     ^~~~~
/usr/include/smesh/SMESH_Gen.hxx: In constructor ‘SMESH_Gen::TAlgoStateError::TAlgoStateError()’:
/usr/include/smesh/SMESH_Gen.hxx:117:25: warning: ‘SMESH_Gen::TAlgoStateError::_algoDim’ will be initialized after [-Wreorder]
     int                 _algoDim;
                         ^~~~~~~~
/usr/include/smesh/SMESH_Gen.hxx:116:25: warning:   ‘const SMESH_Algo* SMESH_Gen::TAlgoStateError::_algo’ [-Wreorder]
     const SMESH_Algo*   _algo;
                         ^~~~~
/usr/include/smesh/SMESH_Gen.hxx:120:5: warning:   when initialized here [-Wreorder]
     TAlgoStateError(): _algoDim(0),_algo(0),_name(SMESH_Hypothesis::HYP_OK) {}
     ^~~~~~~~~~~~~~~
/usr/include/smesh/SMESH_Gen.hxx:116:25: warning: ‘SMESH_Gen::TAlgoStateError::_algo’ will be initialized after [-Wreorder]
     const SMESH_Algo*   _algo;
                         ^~~~~
/usr/include/smesh/SMESH_Gen.hxx:115:25: warning:   ‘TAlgoStateErrorName SMESH_Gen::TAlgoStateError::_name’ [-Wreorder]
     TAlgoStateErrorName _name;
                         ^~~~~
/usr/include/smesh/SMESH_Gen.hxx:120:5: warning:   when initialized here [-Wreorder]
     TAlgoStateError(): _algoDim(0),_algo(0),_name(SMESH_Hypothesis::HYP_OK) {}
     ^~~~~~~~~~~~~~~
In file included from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:44:
/usr/include/smesh/StdMeshers_MaxLength.hxx: At global scope:
/usr/include/smesh/StdMeshers_MaxLength.hxx:39:33: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   void SetLength(double length) throw(SALOME_Exception);
                                 ^~~~~
In file included from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:45:
/usr/include/smesh/StdMeshers_LocalLength.hxx:43:33: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   void SetLength(double length) throw(SALOME_Exception);
                                 ^~~~~
/usr/include/smesh/StdMeshers_LocalLength.hxx:44:39: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   void SetPrecision(double precision) throw(SALOME_Exception);
                                       ^~~~~
In file included from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:46:
/usr/include/smesh/StdMeshers_NumberOfSegments.hxx:51:77: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   const std::vector<double>& BuildDistributionExpr( const char*, int, int ) throw ( SALOME_Exception );
                                                                             ^~~~~
/usr/include/smesh/StdMeshers_NumberOfSegments.hxx:52:91: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   const std::vector<double>& BuildDistributionTab( const std::vector<double>&, int, int ) throw ( SALOME_Exception );
                                                                                           ^~~~~
/usr/include/smesh/StdMeshers_NumberOfSegments.hxx:59:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw (SALOME_Exception);
     ^~~~~
/usr/include/smesh/StdMeshers_NumberOfSegments.hxx:81:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw (SALOME_Exception);
     ^~~~~
/usr/include/smesh/StdMeshers_NumberOfSegments.hxx:96:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw (SALOME_Exception);
     ^~~~~
/usr/include/smesh/StdMeshers_NumberOfSegments.hxx:104:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw (SALOME_Exception);
     ^~~~~
/usr/include/smesh/StdMeshers_NumberOfSegments.hxx:116:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw (SALOME_Exception);
     ^~~~~
/usr/include/smesh/StdMeshers_NumberOfSegments.hxx:124:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw (SALOME_Exception);
     ^~~~~
/usr/include/smesh/StdMeshers_NumberOfSegments.hxx:134:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw (SALOME_Exception);
     ^~~~~
/usr/include/smesh/StdMeshers_NumberOfSegments.hxx:142:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw (SALOME_Exception);
     ^~~~~
/usr/include/smesh/StdMeshers_NumberOfSegments.hxx:154:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw (SALOME_Exception);
     ^~~~~
/usr/include/smesh/StdMeshers_NumberOfSegments.hxx:162:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw (SALOME_Exception);
     ^~~~~
In file included from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:47:
/usr/include/smesh/StdMeshers_AutomaticLength.hxx:58:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw(SALOME_Exception);
     ^~~~~
/usr/include/smesh/StdMeshers_AutomaticLength.hxx:64:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw(SALOME_Exception);
     ^~~~~
/usr/include/smesh/StdMeshers_AutomaticLength.hxx:77:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw(SALOME_Exception);
     ^~~~~
In file included from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:50:
/usr/include/smesh/StdMeshers_Deflection1D.hxx:41:36: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   void SetDeflection(double value) throw(SALOME_Exception);
                                    ^~~~~
In file included from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:51:
/usr/include/smesh/StdMeshers_Arithmetic1D.hxx:46:53: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   void SetLength(double length, bool isStartLength) throw(SALOME_Exception);
                                                     ^~~~~
In file included from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:52:
/usr/include/smesh/StdMeshers_MaxElementArea.hxx:42:35: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
   void SetMaxArea(double maxArea) throw(SALOME_Exception);
                                   ^~~~~
In file included from /usr/include/smesh/StdMeshers_Regular_1D.hxx:35,
                 from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:53:
/usr/include/smesh/StdMeshers_FixedPoints1D.hxx:47:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw(SALOME_Exception);
     ^~~~~
/usr/include/smesh/StdMeshers_FixedPoints1D.hxx:50:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw(SALOME_Exception);
     ^~~~~
In file included from /home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:57:
/usr/include/smesh/StdMeshers_LengthFromEdges.hxx:45:5: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
     throw (SALOME_Exception);
     ^~~~~
/home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp: In member function ‘Mesh::MeshObject* MeshPart::Mesher::createMesh() const’:
/home/mike/free-cad-code/src/Mod/MeshPart/App/Mesher.cpp:314:37: error: ‘get’ is not a member of ‘SMESH_Gen’
     SMESH_Gen* meshgen = SMESH_Gen::get();
                                     ^~~
make[2]: *** [src/Mod/MeshPart/App/CMakeFiles/MeshPart.dir/build.make:163: src/Mod/MeshPart/App/CMakeFiles/MeshPart.dir/Mesher.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:2489: src/Mod/MeshPart/App/CMakeFiles/MeshPart.dir/all] Error 2
make: *** [Makefile:130: all] Error 2
User avatar
PrzemoF
Veteran
Posts: 3520
Joined: Fri Jul 25, 2014 4:52 pm
Contact:

Re: Compile on Linux with gcc-c++ 8.0.1

Post by PrzemoF »

Hi Mike,
Older gcc works fine for you? I have gcc version 7.3.1 20180303 (Red Hat 7.3.1-5) (GCC) and I don't see the error.
Post Reply