Building error regarding Qt verison

■I was trying to build ParaView on Ubuntsu 18.04, foloowing

https://gitlab.kitware.com/paraview/paraview/blob/master/Documentation/dev/build.md

■And when I executed the following,

cmake -GNinja -DPARAVIEW_USE_PYTHON=ON -DPARAVIEW_USE_MPI=ON -DVTK_SMP_IMPLEMENTATION_TYPE=TBB -DCMAKE_BUILD_TYPE=Release …/paraview

■I get warnings and errors like

CMake Warning at VTK/CMake/vtkModule.cmake:4222 (find_package):
Could not find a configuration file for package “Qt5” that is compatible
with requested version “5.12”.

The following configuration files were considered but not accepted:

/usr/lib/x86_64-linux-gnu/cmake/Qt5/Qt5Config.cmake, version: 5.9.5

Call Stack (most recent call first):
Qt/Core/CMakeLists.txt:166 (vtk_module_find_package)

CMake Error at VTK/CMake/vtkModule.cmake:4228 (message):
Could not find the Qt5 external dependency.
Call Stack (most recent call first):
Qt/Core/CMakeLists.txt:166 (vtk_module_find_package)

– Configuring incomplete, errors occurred!
See also “/home/kazuya/paraview_build/CMakeFiles/CMakeOutput.log”.
See also “/home/kazuya/paraview_build/CMakeFiles/CMakeError.log”.

■As the warning says, I thought that this is due to Qt version, so installed Qt 5.12. And this is apparently okay as below.

kazuya@en005031:~/Qt5.12.0/5.12.0/gcc_64/lib$ qmake --version
QMake version 3.1
Using Qt version 5.12.0 in /home/kazuya/Qt5.12.0/5.12.0/gcc_64/lib

■I’ve got no idea how to solve this, so I’d be really grateful someone could help me.
Thanks in advance. Kazuya.

Clearly, you should configure CMake to find Qt 5.12 instead of 5.9.5

Thank you for your response. Could you specifically tell me how I can do this?

First clean your build dir, then, something like:

cmake -DQt5_DIR=~/Qt5.12.0/5.12.0/lib/cmake/Qt5 ../paraview

1 Like

■Now, the error regarding Qt has hopefully gone, but the next step ninja doesn’t work. In /paraview_build/bin, I only find
paraview.conf
paraview-config

After cmake, there were some suspicious “Failed”, “not found” as below, which might be related?

kazuya@en005031:~/paraview_build$ cmake -DQt5_DIR=/home/kazuya/Qt5.12.0/5.12.0/gcc_64/lib/cmake/Qt5 …/paraview
– Performing Test CMAKE_HAVE_LIBC_PTHREAD
– Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
– Looking for pthread_create in pthreads
– Looking for pthread_create in pthreads - not found
– Looking for pthread_create in pthread
– Looking for pthread_create in pthread - found
– Found Threads: TRUE

– Looking for getsockname in socket
– Looking for getsockname in socket - not found
– Performing Test COMPILER_SUPPORT_Wshorten64to32
– Performing Test COMPILER_SUPPORT_Wshorten64to32 - Failed
– Performing Test COMPILER_SUPPORT_Wenumconversion
– Performing Test COMPILER_SUPPORT_Wenumconversion - Failed
– Performing Test COMPILER_SUPPORT_Wcpp11extensions
– Performing Test COMPILER_SUPPORT_Wcpp11extensions - Failed
– Performing Test COMPILER_SUPPORT_Wdoublepromotion
– Performing Test COMPILER_SUPPORT_wd981
– Performing Test COMPILER_SUPPORT_wd981 - Failed
– Performing Test COMPILER_SUPPORT_wd2304
– Performing Test COMPILER_SUPPORT_wd2304 - Failed
– Performing Test COMPILER_SUPPORT_STRICTANSI
– Performing Test COMPILER_SUPPORT_STRICTANSI - Failed
– Performing Test COMPILER_SUPPORT_Qunusedarguments
– Performing Test COMPILER_SUPPORT_Qunusedarguments - Failed
– Looking for sys/endian.h
– Looking for sys/endian.h - not found
– Looking for HAVE_BSWAP_16
– Looking for HAVE_BSWAP_16 - not found
– Looking for HAVE_BSWAP_32
– Looking for HAVE_BSWAP_32 - not found
– Looking for HAVE_BSWAP_64
– Looking for HAVE_BSWAP_64 - not found
– Check size of __int64
– Check size of __int64 - failed
– Check size of unsigned __int64
– Check size of unsigned __int64 - failed
– Looking for arc4random_buf
– Looking for arc4random_buf - not found
– Looking for arc4random
– Looking for arc4random - not found
– Looking for off_t
– Looking for off_t - not found
CMake Warning at VTK/Rendering/OpenGL2/CMakeLists.txt:359 (message):
X11::Xcursor not found; custom cursors will be ignored.

– Looking for shl_load in dld;
– Looking for shl_load in dld; - not found
– Looking for 16 include files sys/types.h, …, ansidecl.h
– Looking for 16 include files sys/types.h, …, ansidecl.h - not found
– Looking for 17 include files sys/types.h, …, dl.h
– Looking for 17 include files sys/types.h, …, dl.h - not found
– Looking for 17 include files sys/types.h, …, float.h
– Looking for _stat
– Looking for _stat - not found
– Looking for 13 include files sys/file.h, …, mach/mach_time.h
– Looking for 13 include files sys/file.h, …, mach/mach_time.h - not found
– Looking for 13 include files sys/file.h, …, io.h
– Looking for 13 include files sys/file.h, …, io.h - not found
– Looking for 13 include files sys/file.h, …, winsock2.h
– Looking for 13 include files sys/file.h, …, winsock2.h - not found
– Check size of __int64
– Check size of __int64 - failed

– Performing Other Test HAVE___TM_GMTOFF - Failed
– Performing Other Test HAVE_TM_ZONE - Failed
– Performing Other Test HAVE_STRUCT_TM_TM_ZONE - Failed
– Performing Other Test HAVE_STRUCT_VIDEOCONFIG - Failed
– Performing Other Test HAVE_STRUCT_TEXT_INFO - Failed
– Looking for _getvideoconfig
– Looking for _getvideoconfig - not found
– Looking for gettextinfo
– Looking for gettextinfo - not found
– Looking for _scrsize
– Looking for _scrsize - not found
– Looking for GetConsoleScreenBufferInfo
– Looking for GetConsoleScreenBufferInfo - not found
– Looking for setsysinfo
– Looking for setsysinfo - not found
– Checking IF your system converts long double to (unsigned) long values with special algorithm… no
– Checking IF your system can convert (unsigned) long to long double values with special algorithm… no
– Checking IF the cpu is power9 and cannot correctly converting long double values… no
– Check if the system is big endian
– Searching 16 bit integer

– Looking for _filelengthi64
– Looking for _filelengthi64 - not found
– Looking for strlcat
– Looking for strlcat - not found
– Looking for st_blocksize
– Looking for st_blocksize - not found
– Check size of longlong
– Check size of longlong - failed

– Check size of uchar
– Check size of uchar - failed

– Check size of schar
– Check size of schar - failed
– Performing Test have_flag_logical-op-parentheses
– Performing Test have_flag_logical-op-parentheses - Failed
– Performing Test have_flag_shift-op-parentheses
– Performing Test have_flag_shift-op-parentheses - Failed
– Performing Test have_flag_tautological-compare
– Testing HDF5 Multi_Dataset - NOT FOUND
– Testing HDF5 Collective_metadata - NOT FOUND
– Testing HDF5 H5Pset_file_space_strategy - NOT FOUND
– Performing Test CHECK_HAVE_STAT64_STRUCT
– Performing Test CHECK_HAVE_STAT64_STRUCT - Failed
– Found Git: /usr/bin/git (found version “2.17.1”)
– Check size of long float
– Check size of long float - failed
– Check size of long double
– Check size of long double - done
– Check size of void *
– Check size of void * - done
– Bitwidth Mapping: preferring long over long long for c++11 compatibility
– Bitwidth Mapping Results:
– conduit::int8 native type: signed char
– conduit::int16 native type: signed short
– conduit::int32 native type: signed int
– conduit::int64 native type: signed long
– conduit::uint8 native type: unsigned char
– conduit::uint16 native type: unsigned short
– conduit::uint32 native type: unsigned int
– conduit::uint64 native type: unsigned long
– conduit::float32 native type: float
– conduit::float64 native type: double
– Enabled modules: VTK(140), ParaView(39 + 2)
– Configuring done
– Generating done
– Build files have been written to: /home/kazuya/paraview_build
kazuya@en005031:~/paraview_build$ ninja
ninja: error: loading ‘build.ninja’: No such file or directory

If you want to use ninja, you should configure for it.

First clean your build dir, then, something like:

cmake -GNinja -DQt5_DIR=~/Qt5.12.0/5.12.0/lib/cmake/Qt5 ../paraview

1 Like

Now I have successfully completed build and was able to run ParaView.
Thank you very much for your kind help!

A post was split to a new topic: Build against Qt 5.9