Plugin for paraview compiled for offscreen

I’m trying to compile a paraview plugin for a system that has paraview compiled as offscreen.

The plugin is

Unfortunately, when I try to make this, I get errors about libEGL

make[2]: *** No rule to make target ‘/usr/lib64/nvidia/’, needed by ‘’. Stop.

If I add the path to to the target_link_libraries in the plugin CMakeLists.txt file, I still have this problem.

Does something special need to be done to build plugins against paraview compiled for offscreen?