How does one actually build the Catalyst Examples?

My attempt on a linux HPC cluster with with lots of guessing involved:

git clone https://github.com/Kitware/ParaView.git
cd ParaView/Examples/Catalyst/Fortran90FullExample
mkdir build
cd build
cmake -DCMAKE_PREFIX_PATH=/sw/installed/ParaView/5.5.2-intel-2018a-mpi/ ..

The output reads:

-- The C compiler identification is GNU 6.4.0
-- The CXX compiler identification is GNU 6.4.0
-- Check for working C compiler: /sw/installed/GCCcore/6.4.0/bin/gcc
-- Check for working C compiler: /sw/installed/GCCcore/6.4.0/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /sw/installed/GCCcore/6.4.0/bin/g++
-- Check for working CXX compiler: /sw/installed/GCCcore/6.4.0/bin/g++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Skipping Fortran90FullExample because `USE_CATALYST` is not set.
-- Configuring done
-- Generating done
-- Build files have been written to: .

So, obviously I need to set USE_CATALYST, but how? What is the command?

Update

I did finally succeed at building and running the example after realizing and fixing the version mismatch between the example and the paraview build.
Checking out the git commit corresponding to my Paraview version 5.5.2 helps.

git clone https://github.com/Kitware/ParaView.git --branch=v5.5.2
cd ParaView/Examples/Catalyst/Fortran90FullExample
mkdir build
cd build
cmake -DCMAKE_PREFIX_PATH=/sw/installed/ParaView/5.5.2-intel-2018a-mpi/ ..
cp ../SampleScripts/coproc.py .
make
mpirun Fortran90FullExample

Did you run make after the cmake step? Cmake generates lower level build scripts (makefiles or other) it does not (generally) do the compilation. Running make will generate the executable which you can then mpirun.

oh, yes my bad, I had forgotten the make command in the updated list of commands at the bottom.

updated my post

I did finally succeed at building and running the example after realizing and fixing the version mismatch between the example and the paraview build.
So I don’t really have an issue any more, for now.

My only concern left is that it’s frustratingly hard to compile the example(s) without instructions on how to, and I only succeeded, because a colleague of mine came up with the -DCMAKE_PREFIX_PATH-option that I did not know of.

Instructions on how to compile and run the examples would be fantastic for people like me who have a code that they intend to extend with Catalyst.

Agreed. We aim to make Catalyst as a whole a lot easier to build and link to over the next couple of releases. Better documenting the examples would help. A good place to do that would be at the top of Chapter 5 of the ParaviewCatalyst guide. Feel free to add a feature request issue on ParaView’s gitlab issue tracker to help remind us to do that.

Note: The need for CMAKE_PREFIX_PATH is likely a regression that started with PV 5.6. Turning off VTK-M should make it uneccessary.

thanks

I think part of the issue is that with commit cc06237 that the Catalyst examples aren’t as easy to compile now as stand-alone examples because the USE_CATALYST CMake option was removed. Additionally, there’s no find_package(ParaView ...) either. This should get changed back.