CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Installation

[OpenFOAM.org] Issues compiling ParaView 5.4 with Qt 5, on OpenFOAM-dev

Register Blogs Community New Posts Updated Threads Search

Like Tree4Likes
  • 1 Post By wyldckat
  • 1 Post By wyldckat
  • 1 Post By wyldckat
  • 1 Post By sita

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 25, 2019, 09:44
Default Issues compiling ParaView 5.4 with Qt 5, on OpenFOAM-dev
  #1
Senior Member
 
Sita Drost
Join Date: Mar 2009
Location: Arnhem, The Netherlands
Posts: 227
Rep Power: 18
sita is on a distinguished road
Hi all,


I ran into the same error while building ParaView for OpenFOAM-dev on a Scientific Linux cluster: cmake complaining about not being able to find Qt5X11ExtrasConfig.cmake or qt5x11extras-config.cmake.


The thing is, we already have OpenFOAM-5.x, and those cmake config files do exist, just not where cmake expects them apparently. I tried for a while to follow the instructions in the error message (Add the installation prefix of "Qt5X11Extras" to CMAKE_PREFIX_PATH or set "Qt5X11Extras_DIR" to a directory containing one of the above files), but I'm not sufficiently experienced with cmake to do this properly, so I kept getting the same error.


What I tried so far is using export, cmake -D CMAKE_PREFIX_PATH=/path/to/Qt5X11Extras, and set (deleting CMakeCache.txt after each failed attempt to run makeParaView). Using export didn't make a difference (I read somewhere that "CMAKE_PREFIX_PATH is not an environment variable, but rather a build directive"), the other two gave me errors.


What should I do to tell cmake where to find these files?



Many thanks!
Sita


P.S. For now I'm just using the ParaView that came with OpenFOAM-5.x. As far as I can tell it's exactly the same version (5.4.0), so I'm all sorted really, it's just that I hate getting errors like that without being able to resolve them...


[Moderator note: This post and the posts below were moved from Paraview cmake error - to avoid conflict between OpenFOAM versions/variants]

Last edited by wyldckat; April 26, 2019 at 08:05. Reason: see "Moderator note:"
sita is offline   Reply With Quote

Old   April 25, 2019, 12:32
Default
  #2
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,975
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Quick questions @sita:
  1. Which exact Qt5 version are you using and how was it installed and where?
  2. Are you using the makeParaView script? And if so, with what arguments?
__________________
wyldckat is offline   Reply With Quote

Old   April 25, 2019, 14:49
Default
  #3
Senior Member
 
Sita Drost
Join Date: Mar 2009
Location: Arnhem, The Netherlands
Posts: 227
Rep Power: 18
sita is on a distinguished road
Hi Bruno,
Thanks for getting back!
1. Not sure, think it's 5.4.0, won't be able to check until Monday, I'll post it here then. I'll also ask my colleague how and when he installed that (and how we ended up having multiple installs in completely different locations).
2. Yes, I'm running the makeParaView script, without any arguments (following the instructions here: https://openfoam.org/download/source/).

Thanks for your help so far,
Sita
sita is offline   Reply With Quote

Old   April 25, 2019, 18:42
Default
  #4
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,975
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Quick answer @sita: Qt 5.6 is the minimum version needed; and makeParaView will only work out-of-the-box if qmake answers to the version number request as a valid Qt 5.6 or newer...
wyldckat is offline   Reply With Quote

Old   April 26, 2019, 02:04
Default
  #5
Senior Member
 
Sita Drost
Join Date: Mar 2009
Location: Arnhem, The Netherlands
Posts: 227
Rep Power: 18
sita is on a distinguished road
Ah right, that explains. I remember seeing a warning at some point, something about expecting Qt version 5.9.0 and finding 5.4.0, but I didn't think much of that. I'll try installing a newer version, see how that goes.

Thanks a lot for your help again!
Sita

EDIT: Perhaps the installation instructions (https://openfoam.org/download/source...r-compilation/) should be adapted; there it says Qt version 4.8 or above is required by ParaView

Last edited by sita; April 26, 2019 at 02:42. Reason: Additional info
sita is offline   Reply With Quote

Old   April 26, 2019, 08:03
Default
  #6
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,975
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
At the moment, only ParaView 5.4 is being supported with OpenFOAM 6 and dev, which can/should be built with Qt 4, to keep things simple.

At the moment, the Qt 5 versions available in Linux Distributions is still a bit wonky, in the sense that the latest ParaView versions (5.5 and 5.6) are dependent on Qt 5, but require a rather modern Qt 5 version. For example, Ubuntu 14.04 and 16.04 do not have the necessary Qt 5 versions and OpenFOAM 6 still supports those old Ubuntu versions out-of-the-box: https://openfoam.org/download/6-ubuntu/
sita likes this.
wyldckat is offline   Reply With Quote

Old   April 30, 2019, 06:16
Default
  #7
Senior Member
 
Sita Drost
Join Date: Mar 2009
Location: Arnhem, The Netherlands
Posts: 227
Rep Power: 18
sita is on a distinguished road
Alright, so it turns out we have qt5.9.1 installed, but there are also other versions of Qt5 and Qt4 installed. This newest version, Qt5.9.1, lives under /opt/ (I'm guessing our system administrator didn't want it to interfere with older versions).


So if makeParaView needs Qt >= 5.6, how do I tell Cmake where to find this newest version?


Or, if as Bruno says, ParaView should be built with Qt4, how do I tell makeParaView to use Qt4?


Thanks in advance!
Sita


P.S. I already tried setting QMAKE_PATH and CMAKE_PATH in makeParaView, but that didn't seem to help

P.P.S I've attached the output of ./makeParaView
Attached Files
File Type: txt makeParaView.txt (42.8 KB, 9 views)

Last edited by sita; April 30, 2019 at 06:48. Reason: Extra info
sita is offline   Reply With Quote

Old   April 30, 2019, 19:33
Default
  #8
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,975
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Quote:
Originally Posted by sita View Post
Or, if as Bruno says, ParaView should be built with Qt4, how do I tell makeParaView to use Qt4?
Example given here: https://openfoamwiki.net/index.php/I...HEL#CentOS_6.8 - step #14.1
Code:
./makeParaView -qmake $WM_THIRD_PARTY_DIR/platforms/$WM_ARCH$WM_COMPILER/qt-4.8.6/bin/qmake -mpi -python > log.makePV 2>&1
In your case, if Qt 4 is installed at "/opt/qt-4.8.6", you could then use:
Code:
./makeParaView -qmake /opt/qt-4.8.6/bin/qmake -mpi -python > log.makePV 2>&1
This is expecting to build with MPI and Python support as well, along with redirecting the screen output into the log file "log.makePV"...
cpadam likes this.
wyldckat is offline   Reply With Quote

Old   May 1, 2019, 01:52
Default
  #9
Senior Member
 
Sita Drost
Join Date: Mar 2009
Location: Arnhem, The Netherlands
Posts: 227
Rep Power: 18
sita is on a distinguished road
Awesome, thanks a million!
Sita


EDIT: It worked, thank you so much!

Last edited by sita; May 1, 2019 at 03:30. Reason: Additional info
sita is offline   Reply With Quote

Old   May 1, 2019, 03:49
Default
  #10
Senior Member
 
Sita Drost
Join Date: Mar 2009
Location: Arnhem, The Netherlands
Posts: 227
Rep Power: 18
sita is on a distinguished road
Sorry, another issue came up once I managed to build ParaView. Now when I run paraFoam, ParaView starts, but gives me this pop-up window, saying "OpenGL support inadequate!" (see attached screenshot + errors from the terminal). After clicking OK, ParaView starts up alright, but after loading my case, I can't see my geometry.

The ParaView forum says to update the graphics driver to resolve this, or to use
Code:
 MESA_GL_VERSION_OVERRIDE=3.2 ./bin/paraview
but I'm not sure how to do this. As far as I know our cluster doesn't have a graphics card, so I don't know what/where to update, and as for the MESA_GL_VERSION_OVERRIDE, I don't know where to add this (adding it to the OpenFOAM bashrc didn't do the trick: that caused ParaView to start up upon sourcing OpenFOAM, and to crash after attempting to load a case...).

In OpenFOAM-5.x ParaView works just fine (same version, 5.4.0), so I have a feeling that it's just some option somewhere. Does anyone know how to resolve this?

Many thanks!
Sita
Attached Images
File Type: png OpenGL_error.PNG (31.2 KB, 8 views)
Attached Files
File Type: zip paraview_errors.zip (20.0 KB, 0 views)

Last edited by sita; May 1, 2019 at 03:51. Reason: Forgot attachments
sita is offline   Reply With Quote

Old   May 1, 2019, 10:10
Default
  #11
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,975
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Quick answer: I knew I was forgetting to mention something... and one of the things was this page: https://openfoamwiki.net/index.php/I...n/ParaView/FAQ

But the other was that by default, it builds with the OpenGL2 standard, more specifically v3.3 and newer. Even if you try:
Code:
MESA_GL_VERSION_OVERRIDE=3.2 ./bin/paraview
it will likely not work.

So with ParaView 5.4.0, you can still build with the older OpenGL standard, by adding this argument to the makeParaView call:
Code:
-rendering OpenGL
e.g.:
Code:
./makeParaView -qmake $WM_THIRD_PARTY_DIR/platforms/$WM_ARCH$WM_COMPILER/qt-4.8.6/bin/qmake -mpi -python -rendering OpenGL > log.makePV 2>&1
Keep in mind that as of ParaView 5.5, we can no longer build with the old OpenGL support and the work around is to build Mesa with OpenGL2 to use the CPU for rendering... which is a lot slower and I haven't tried in any other Linux Distribution other than Ubuntu...
hamedhiv likes this.
wyldckat is offline   Reply With Quote

Old   May 2, 2019, 01:26
Default
  #12
Senior Member
 
Sita Drost
Join Date: Mar 2009
Location: Arnhem, The Netherlands
Posts: 227
Rep Power: 18
sita is on a distinguished road
Thanks a lot, I'll give that a try!


EDIT: It worked! Thanks Bruno, you're a star!
wyldckat likes this.
sita is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
[OpenFOAM.org] Two different versions of ParaView with same OpenFOAM release FJSJ OpenFOAM Installation 2 July 23, 2017 05:48
Updated native OpenFOAM reader for ParaView 5.3 opencfd OpenFOAM Announcements from ESI-OpenCFD 4 July 13, 2017 10:14
[OpenFOAM.org] Using OpenFOAM 2.3.0 from Deb pack in Ubuntu 14.04 + ParaView 5 from OpenFOAM 4.1 ad2eb OpenFOAM Installation 12 May 28, 2017 14:30
Statically Compiling OpenFOAM Issues herzfeldd OpenFOAM Installation 21 January 6, 2009 09:38
OpenFOAM and Paraview install issues spridal86 OpenFOAM Installation 7 February 13, 2008 13:15


All times are GMT -4. The time now is 06:37.