Additional include directories with paraview plugin builder

On windows, adding an include directory with include_directories(path) in cmakelists.txt worked. The same does not work with paraview plugin builder, I have also tried adding it into a plugin.cmake file with no success. How do I add additional include directories when building plugins with pv plugin builder?

please share a failing plugin example and steps to reproduce.

I have a qt plugin written in c++ and have source files in a directory called ‘shared’ outside of my plugin directory. On windows, I can include the directory in an ide or in the cmakelists.txt contained in the plugin directory.

In the cmakelists.txt file I have:


But when I try to build with pv plugin builder (paraview v5.9.0) I get an error saying the file I tried to include was not found.

I have attached a small plugin and the directory I would like to include in the build.
pvClone.tar (104 KB)

To reproduce build the plugin with pvpluginbuilder by setting the pvOptUMesh directory as the plugin path, while the ‘shared’ directory is contained in the same folder as the pvOptUMesh directory. I built with pv v5.9.0

See Examples/Plugins/ComplexPluginArchitecture in ParaView source code for an example to do what you want, it include a shared vtk module.

I have followed the example and made my ‘shared’ directory a vtk module, when I compile I get an error saying the shared.lib is not found for the vtk module. Any ideas?

Please share your failing to build plugin (244.9 KB)
I am building from the pvOptAirfoil directory against paraview superbuild v5.9.1

Looking at your shared utils, there is no reason to make it a vtk module, it should just be a lib, so that should be actually easier to do.

I am now using many vtk classes in my shared utils, and I believe it makes sense to have a vtk module. It seems to build correctly, but I receive an error when I try to load the shared library:

ERROR: In C:\glr\builds\paraview\paraview-ci\build\superbuild\paraview\src\Remoting\Core\vtkPVPluginLoader.cxx, line 530
vtkPVPluginLoader (000002C80A3791D0): The specified module could not be found.

The plugin architecture has changed slightly, and is now built from the directory above the shared utils against paraview superbuild 5.9.1. (261.5 KB)

Also, you had mentioned I can combine the filters into one plugin. I attempted to do that here but a shared library was generated for each. How do I approach that?

Not sure about your error.

Regarding the number of libraries, each one is geneated for each module.

I finally was able to get the project to compile with the sharedUtils implemented as a library instead of a vtk module. (261.9 KB)

However, I am still running into the same error “The specified module could not be found” when loading either of the generated shared libraries.
There is no known cause for this?

This would require a much deeper investigation.