-
-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix #11449 3rdPart/salomesmesh vtk 9.3 compatibility #11496
Conversation
minimum required version is 7.1
@@ -1026,7 +1026,12 @@ void SMDS_UnstructuredGrid::BuildLinks() | |||
GetLinks()->Allocate(this->GetNumberOfPoints()); | |||
GetLinks()->Register(this); | |||
//FIXME: vtk9 | |||
#if VTK_VERSION_NUMBER < VTK_VERSION_CHECK(9,3,0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where are VTK_VERSION_NUMBER and VTK_VERSION_CHECK are defined?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
https://kitware.github.io/paraview-docs/latest/cxx/vtkVersionMacros_8h.html
I'm not sure whre it gets included but compilation suceeded for me on arch and on ubuntu
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hhhmmm I'm not finding these on 7.1.1 source code though
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah seems it was added in vtk 8 https://gitlab.kitware.com/vtk/vtk/-/commit/2b94edcd2b74fb6f523c96a01c6b930313053215
#if VTK_VERSION_NUMBER < VTK_VERSION_CHECK(9,3,0) | ||
GetLinks()->BuildLinks(this); | ||
#else | ||
GetLinks()->SetDataSet(this); | ||
GetLinks()->BuildLinks(); | ||
#endif |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
how about:
#if VTK_VERSION_NUMBER < VTK_VERSION_CHECK(9,3,0) | |
GetLinks()->BuildLinks(this); | |
#else | |
GetLinks()->SetDataSet(this); | |
GetLinks()->BuildLinks(); | |
#endif | |
#if VTK_MAJOR_VERSION >= 9 && VTK_MINOR_VERSION >= 3 | |
GetLinks()->SetDataSet(this); | |
GetLinks()->BuildLinks(); | |
#else | |
GetLinks()->BuildLinks(this); | |
#endif |
these should be available on 7.1: https://gitlab.kitware.com/vtk/vtk/-/blob/v7.1.0/Common/Core/vtkVersionMacros.h.in?ref_type=tags
I think the PR should be fine as the version check macro is used inside the VTK_CELL_ARRAY_V2 which IIRC is also defined for >= vtk8. |
vtkMTimeType was introduced in vtk 7.1 so minimum required vtk version with this is 7.1 which available on ubuntu 20.04
@wwmayer