Problem VTK_MAJOR_VERSION

Submitted by Zsang on Thu, 04/11/2024 - 11:46

Hello everyone,

I am trying to install CFDEMcoupling on Fedora Linux.

Generally I am following the installation of CFDEMcoupling from :https://www.cfdem.com/media/CFDEM/docu/CFDEMcoupling_Manual.html

For now the good thing is that I have downloaded all software and compiled OpenFOAM successfully, so the only work is the last step to compile LIGGGHTS® and CFDEM®coupling with ‘cfdemCompCFDEMall’ command. However the problem occurs.

In the beginning I met the error message as below:

make[1]: Entering directory '/home/sang/Software/LIGGGHTS/LIGGGHTS-PUBLIC/src/Obj_auto'
make[1]: warning: -j8 forced in submake: resetting jobserver mode.
Makefile:820: *** 'Could not obtain VTK_MAJOR_VERSION. As AUTOINSTALL_VTK is not set to "ON" we cannot continue'. Stop.
make[1]: Leaving directory '/home/sang/Software/LIGGGHTS/LIGGGHTS-PUBLIC/src/Obj_auto'
make: *** [Makefile:114: auto] Error 2
make[1]: Entering directory '/home/sang/Software/LIGGGHTS/LIGGGHTS-PUBLIC/src/Obj_auto'
make[1]: warning: -j8 forced in submake: resetting jobserver mode.
Makefile:820: *** 'Could not obtain VTK_MAJOR_VERSION. As AUTOINSTALL_VTK is not set to "ON" we cannot continue'. Stop.
make[1]: Leaving directory '/home/sang/Software/LIGGGHTS/LIGGGHTS-PUBLIC/src/Obj_auto'
make: *** [Makefile.shlib:69: auto] Error 2

I tried several solutions offered from different forums.

1. Because VTK has been installed in my system before for other softwares. Therefore, at first I added the VTK_INC_USR and VTK_LIB_USR path to the Makefile.user. Unfortunately it doesn't work.

2. Because I thought the previous VTK is not in my own $HOME directory, it cannot be detected. Then I set AUTOINSTALL_VTK to ON. But due to the sudo permission, the compilation is failed.

3. Then I intsalled another VTK manually in $HOME/Software/LIGGGHTS/VTK according to the commands from another forum as following. In the end VTK-9.3 was installed. and I changed the VTK_INC_USR and VTK_LIB_USR path to my own $HOME directory. Unfortunately it doesn't work.

4. In the end, I found the VTK_MAJOR_VERSION and so on in vtkVERSIONQuick.h file. And I directly defined it in the makefile.user. But it still has the sam error.

Here is part of my Makefile.user, and I also uploaded it here:

USE_MPI = "ON"
# CATALYST: "ON" or "OFF"
USE_CATALYST = "OFF"
# VTK: "ON" or "OFF"
USE_VTK = "ON"
AUTOINSTALL_VTK = "OFF"

# VTK specific variables
#
# Path that contains the includes (vtkVersion.h)
VTK_INC_USR=-I/home/sang/Software/LIGGGHTS/VTK/vtk-build/Common/Core
# Path that contains the VTK libraries
VTK_LIB_USR=-L/home/sang/Software/LIGGGHTS/VTK/vtk-build/lib64
# Additional VTK libraries to include
#VTK_ADDLIBS_USR=
#VTK_APPENDIX_USR=pv-5.3
#Specify the version of VTK installed on the system
VTK_MAJOR_VERSION=9
VTK_MINOR_VERSION=3
VTK_EPOCH_VERSION=20230101

I found In my include directory (/home/sang/Software/LIGGGHTS/VTK/vtk-build/Common/Core), there are vtkVERSIONFull.h, vtkVERSIONMacro.h, vtkVERSIONQuick.h files, but no vtkVERSION.h file. I don't know whether this can result in the error.

If you have any idea, please share with me. Thank you very much in advance.

AttachmentSize
Plain text icon makefile.user_.txt6.69 KB