Build paraview with Openturns

(Zack) #1

Hi all,

I am trying to build Paraview 5.6.1 in my Linux-OS (Archlinux) with Openturns, but I have this error:

 CMake Error at VTK/Filters/OpenTurns/CMakeLists.txt:1 (find_package):
 By not providing "FindOpenTURNS.cmake" in CMAKE_MODULE_PATH this project
 has asked CMake to find a package configuration file provided by
 "OpenTURNS", but CMake did not find one.

 Could not find a package configuration file provided by "OpenTURNS"
 (requested version 1.8) with any of the following names:

 OpenTURNSConfig.cmake
 openturns-config.cmake

Add the installation prefix of "OpenTURNS" to CMAKE_PREFIX_PATH or set
"OpenTURNS_DIR" to a directory containing one of the above files.  If
"OpenTURNS" provides a separate development package or SDK, be sure it has
been installed.

Did I miss something? cause the installation process mentions that I only have to turn on the Cmake option PARAVIEW_USE_OPENTURNS. btw, without Openturns, Paraview is built with no errors.

(Mathieu Westphal (Kitware)) #2

ParaView is looking for OpenTURNS, did you install it on your machine ?

(Zack) #3

Thanks Mathieu for your quick answer.
yes, I did. I will try to reinstall it again.

(Mathieu Westphal (Kitware)) #4

Ok, so you only need to inform ParaView where to find OpenTURNS.

On ubuntu for example, there is a file here :/usr/local/lib/cmake/openturns/OpenTURNSConfig.cmake

do you have this file ?

(Zack) #5

No, I think I installed the wrong version, Paraview needs OpenTURNS 1.8, I will try to install this one.

(Zack) #6

I installed OpenTURNS1.8, it is installed in /home/xxxx/.local/share/openturns and there is no cmake file called OpenTURNSConfig.cmak. it contains three folders /doc ‘/examples’ and ‘/validation’.

I followed the installation instructions in OpenTURNS website (http://openturns.github.io/openturns/latest/install.html)

git clone https://github.com/openturns/openturns.git
cd openturns
cmake -DCMAKE_INSTALL_PREFIX=~/.local .
make install
(Mathieu Westphal (Kitware)) #7

Why are you building from sources ?

(Zack) #8

To install older version (OpenTURNS 1.8). The pkg-manager contains only the latest version. Am I wrong ?

(Mathieu Westphal (Kitware)) #10

OpenTURNS is backward compatible, you can build ParaView with any version of OpenTURNS after 1.8.

(Zack) #11

OK, I am then confused because in paraview5.6.1/VTK/Filters/OpenTurns/CMakeLists.txt it is written:

find_package(OpenTURNS 1.8 REQUIRED) # !!!! #
# XXX(fixme)
include(${OPENTURNS_USE_FILE})

set(classes
vtkOTDensityMap
....

I will try to install the latest OpenTURNS, I hope that it will work.

(Mathieu Westphal (Kitware)) #12

from cmake doc : https://cmake.org/cmake/help/v3.15/command/find_package.html

The [version] argument requests a version with which the package found should be compatible (format is major[.minor[.patch[.tweak]]] ). The EXACT option requests that the version be matched exactly.

(Mathieu Westphal (Kitware)) #13

I’ve updated my blog post with infos regarding the version of OpenTURNS.

(Zack) #14

Ok, my bad, I am not familiar with cmake. Thanks.

I will try to install latest openturns then.

(Zack) #15

Thanks, OpenTURNS builded successfully. Thanks again for your help.