ParaView installation with Kits and a module requiring a 3rd Party (FFMPEG) fails to be configured against
Building and installing ParaView with Kits and enabling a module requiring a thied party dependency prevent any plugin or paraview based app to be configured against.
Steps to reproduce:
cd $path
git clone https://gitlab.kitware.com/paraview/paraview.git src
cd src
git submodule update --init --recursive
mkdir ../build
mkdir ../install
cd ../build
cmake -GNinja -DPARAVIEW_BUILD_WITH_KITS=ON -DPARAVIEW_ENABLE_FFMPEG -DCMAKE_INSTALL_PREFIX=../install ../src
ninja install
cd ../src/Examples/Plugins/ElevationFilter
mkdir build
cmake -DParaView_DIR=$path/install/lib/cmake/paraview-5.12/ ../
Fails with:
CMake Error at /home/glow/dev/paraview/pv1/install/lib/cmake/paraview-5.12/vtk/VTK-targets.cmake:5568 (set_target_properties):
The link interface of target "VTK::IOFFMPEG-objects" contains:
FFMPEG::avformat
but the target was not found. Possible reasons include:
* There is a typo in the target name.
* A find_package call is missing for an IMPORTED target.
* An ALIAS target is missing.
Call Stack (most recent call first):
/home/glow/dev/paraview/pv1/install/lib/cmake/paraview-5.12/vtk/vtk-config.cmake:149 (include)
/home/glow/dev/paraview/pv1/install/lib/cmake/paraview-5.12/paraview-config.cmake:77 (find_package)
CMakeLists.txt:4 (find_package)
Please note the recent introduction of NO_KIT_EXPORT_IF_SHARED
did NOT fix the issue: vtk/vtk!10929 (merged)
==============================
Was: build of paraview based application with ffmpeg failed
Hello,
I have a paraview based application and I want to add ffmpeg support in it (to save avi format). I build my application on top of paraview master with spack.
The build of paraview with ffmpeg succeed and I can export file in avi format (thanks to @ben.boeckel).
However, I can't build my application because it does not find ffmpeg:
>> 215 CMake Error at /home/billae/install_develop/spackinstaller/spack/opt/spack/linux-ubuntu23.04-skylake/gcc-13.1.0/paraview-master-lgzicckwpmphngih3wmnut4ldg73jlnb/
lib/cmake/paraview-5.12/vtk/VTK-targets.cmake:4761 (set_target_properties):
216 The link interface of target "VTK::IOFFMPEG-objects" contains:
217
218 FFMPEG::avformat
219
220 but the target was not found. Possible reasons include:
221
I tried differents CMAKE flags to give the path to ffmpeg in the config phase of my app (-DFFMPEG_DIR
, -DFFMPEG_ROOT
, -DFFMPEG_LIBAVFORMAT_LIBRARIES
, -DFFMPEG_LIBAVFORMAT_INCLUDE
, -DCMAKE_MODULE_PATH
, -DCMAKE_PREFIX_PATH
) or to add a find_package
to ffmpeg in my app, but nothing seems to help.
If anyone has an idea ? @westphalm