Problems compiling libmesh with VTK enabled

257 views
Skip to first unread message

Daniel Vogler

unread,
Jul 6, 2017, 3:34:38 PM7/6/17
to moose-users
Dear all,

I tried to update my libmesh version as described in

http://mooseframework.org/wiki/PhysicsModules/PhaseField/ImageReader/

by performing

module load advanced_modules
module load vtk-clang
cd ~/projects/moose/scripts
./update_and_rebuild_libmesh.sh --with-vtk-include=$VTKINCLUDE_DIR --with-vtk-lib=$VTKLIB_DIR


my vtk version is not found properly so I re-link
VTKINCLUDE_DIR and VTKLIB_DIR to the proper directory so that my output returns:

checking /opt/moose/VTK-7.0/clang-opt/include/vtk-7.0/vtkConfigure.h usability... yes
checking /opt/moose/VTK-7.0/clang-opt/include/vtk-7.0/vtkConfigure.h presence... yes
checking for /opt/moose/VTK-7.0/clang-opt/include/vtk-7.0/vtkConfigure.h... yes
<<< Linking a test program against the VTK libraries failed >>>
<<< libMesh requires VTK to be configured with -DVTK_Group_MPI:BOOL=ON >>>
<<< Configuring library without VTK support >>>

The full log is attached in
updating_libmesh_opt-moose-vtk-7-0.log.



I went and rebuilt VTK (7.1) from scratch (http://www.vtk.org/Wiki/VTK/Configure_and_Build) and seems to work fine.
However, I get exactly the same problem (
<<< libMesh requires VTK to be configured with -DVTK_Group_MPI:BOOL=ON >>>) when resetting VTKINCLUDE_DIR and VTKLIB_DIR to the new directories as also discussed in this forum (https://groups.google.com/d/topic/moose-users/Kb6s_LWcEnU/discussion).

checking /usr/local/vtk-7.1/include/vtk-7.1//vtkConfigure.h usability... yes
checking /usr/local/vtk-7.1/include/vtk-7.1//vtkConfigure.h presence... yes
checking for /usr/local/vtk-7.1/include/vtk-7.1//vtkConfigure.h... yes
<<< Linking a test program against the VTK libraries failed >>>
<<< libMesh requires VTK to be configured with -DVTK_Group_MPI:BOOL=ON >>>
<<< Configuring library without VTK support >>>

The full log is attached in updating_libmesh_usr-local-vtk-7-1.log.  



I found some advice (http://vtk.1045678.n5.nabble.com/Build-VTK-without-OpenGL-and-with-MPI-td5741478.html) that recommended to turn off the MPI groups, but I think that could get me into trouble in the long run.
Currently I configured VTK-7.1 as shown in attachment vtk_ccmake.png.

Is there a less "patchy" way of configuring this?

Since other users I consulted did not have this problem in the first place (VTK 7.1 directly in /opt/moose/ since they first built MOOSE after I did it seems), I uninstalled the MOOSE environment and rebuild, but it seems like I did not get rid of all dependencies since I ran into the same problem again.
Unfortunately I did not save the output for this.



Any advice would be much appreciated.

Thanks!
Daniel
updating_libmesh_opt-moose-vtk-7-0.log
vtk_ccmake.png

Daniel Vogler

unread,
Jul 6, 2017, 3:35:56 PM7/6/17
to moose-users
One attachment did not seem to upload...
updating_libmesh_usr-local-vtk-7-1.log

Alger, Brian K

unread,
Jul 6, 2017, 3:47:49 PM7/6/17
to moose...@googlegroups.com
I see your MOOSE package contains VTK 7.0 which means that it is fairly old.
I would recommend downloading the latest MOOSE environment package for your platform from http://mooseframework.org/getting-started/
It will contain a properly built VTK 7.1 that is known to work with libmesh.
Remember to restart your terminals after installing the new package so that you pick up the new environment.



--
You received this message because you are subscribed to the Google Groups "moose-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to moose-users+unsubscribe@googlegroups.com.
Visit this group at https://groups.google.com/group/moose-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/moose-users/88b487bc-5860-4846-a972-0a892dd15d03%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

Peterson, JW

unread,
Jul 6, 2017, 4:03:24 PM7/6/17
to moose-users
On Thu, Jul 6, 2017 at 1:47 PM, Alger, Brian K <brian...@inl.gov> wrote:
I see your MOOSE package contains VTK 7.0 which means that it is fairly old.
I would recommend downloading the latest MOOSE environment package for your platform from http://mooseframework.org/getting-started/
It will contain a properly built VTK 7.1 that is known to work with libmesh.
Remember to restart your terminals after installing the new package so that you pick up the new environment.

Yes, a change between VTK-7.0 and VTK-7.1 caused us to require the MPI support in VTK to be turned on, hence the message:

<<< libMesh requires VTK to be configured with -DVTK_Group_MPI:BOOL=ON >>>

Upgrading your MOOSE package as Brian mentioned should fix the issue.

--
John

Daniel Vogler

unread,
Jul 7, 2017, 8:17:46 AM7/7/17
to moose-users
Hi Brian, hi John,

Thanks a lot for the fast help. Everything seems to be working now. 

I'll just follow up on this in case someone experiences the same problem. 

I uninstalled everything and re-installed the MOOSE package. Even after cleaning the git repo, I still had some warnings about moved library packages during libmesh compilation (although VTK was working when I updated my libmesh distro) but libmesh compiled. My moose/test(s) were not compiling, as I had the same error with some old gcc dependencies as here (https://github.com/idaholab/moose/issues/7104). Even though I cleaned the repo, this error persisted. Re-linking the libraries gave me trouble later on as well.

So I decided to start again with a fresh moose clone and everything was working right away. I should've just bitten the bullet right away and start clean.

Thanks again.

Best,
Daniel
Reply all
Reply to author
Forward
0 new messages