to the end of my CMakeLists.txt (lines 375-380) [which, by the way, is not located in the “build” directory, only the parent “paraview-superbuild”] , I get this error if I go through ccmake
CMake Error at CMakeLists.txt:378 (FIND_PACKAGE):
By not providing "FindParaView.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "ParaView",
but CMake did not find one.
Could not find a package configuration file provided by "ParaView" with any
of the following names:
ParaViewConfig.cmake
paraview-config.cmake
Add the installation prefix of "ParaView" to CMAKE_PREFIX_PATH or set
"ParaView_DIR" to a directory containing one of the above files. If
"ParaView" provides a separate development package or SDK, be sure it has
been installed.
This is a little confusing to me as usually the parent directory with whatever I get from github has those files (i.e. if it’s not the superbuild, e.g. via “git clone https://gitlab.kitware.com/paraview/paraview.git”) but the superbuild works so many layers of magic, I have no idea where those files are.
Am I putting the commands in the right place? And if not, how should I go about resolving this issue?
if (PARAVIEW_USE_MPI)
pv_plugin(PhastaSyncIOReader
DESCRIPTION "Phasta SyncIO Reader"
# uncomment AUTOLOAD to have the plugin automatically loaded. Note
# though that this isn't working in PV 5.2 and probably earlier
AUTOLOAD
DEFAULT_ENABLED)
endif()
Since the last known version the plugin was built for was 5.2.0, I’m not sure if anything in there is out of date, or how to fix it - does anyone have any thoughts?
PARAVIEW_ADD_PLUGIN(PhastaSyncIOReader VERSION 1.0
SERVER_MANAGER_XML PhastaSyncIO.xml
SOURCES
vtkPhastaSyncIOMetaReader.cxx
vtkPhastaSyncIOReader.cxx
REQUIRED_ON_SERVER
)
Trying to make the plugin again (I’m totally unfamiliar with this kind of thing, but fortunately I still have some kind of notes - which suggested that to do so I run)
I can get rid of the first error (pertaining to “PARAVIEW_USE_FILE”) by just deleting it, because I don’t know what to replace it with, but I still don’t know how to deal with the second error
The 's CMakeLists.txt may not add the PhastaSyncIOReader plugin.
Call Stack (most recent call first):
CMakeLists.txt:15 (PARAVIEW_ADD_PLUGIN)
[Changing the CMakeLists.txt to more closely match the format here doesn’t change anything
Note that you’ll need to create a paraview.plugin file and use paraview_plugin_scan and paraview_plugin_build to build the plugin. paraview_add_plugin relies on information gathered during the scan and build to perform all of its work (and it avoids it having 30+ CMake parameters).
See this example for how to structure a simple CMake project using a plugin. Yes, there’s boilerplate, but VTK and ParaView are working to ensure that some CMake best practices are followed (and they can’t do all the boilerplate for everyone).
Thanks! That example helped - it seems like there’s been a lot of changes to the structure. I was able to compile some kind of library (.so) file and loaded it into Paraview just fine, but when I tried to open a .phts file with Paraview (which is what the plugin was designed to do), I ran into this error, which is well beyond me, since I didn’t write any of the code for the plugin.
vtkSIProxy.cxx:415 ERR| vtkSISourceProxy (0x2d15cc0): Failed to create 'vtkPhastaSyncIOMetaReader'. This typically means that ParaView does not know about the request class to create an instance of if. Ensure that it has been correctly wrapped using the client-server wrappers and the wrapping has been initialized. Note class names are case-sensitive. Check for typos. Aborting for debugging purposes.
Loguru caught a signal: SIGABRT
Fortunately, I ran through the process of plugin-making with paraview 5.6.0, and that plugin worked just fine. If there’s something simple that I’m missing, I’d take the oppurtunity to work on paraview 5.8.0, but if not, paraview 5.6.0 will certainly get the job done.