make problems

Discussion about building and installing Elmer
Post Reply
Gary R
Posts: 162
Joined: 12 Apr 2012, 07:23
Antispam: Yes
Location: Long Beach CA, USA

make problems

Post by Gary R »

Hi all,
i'm trying to add some capability to my Elmer build and am having make error problems. My setup is:
Debian Buster(testing)
Cmake 3.13.2 compiled with Qt5.11.3
Elmerfem-8.4 of Jan 11 2019 source file
With:
contrib
elmergrid
elmergui
matc
mpi
occ
openmp
paraview
qwt
vtk
Cmake generates the MakeFile fine but when I run make I get the follow error:

Code: Select all

[ 63%] Built target ElmerGUI_autogen
[ 63%] Building CXX object ElmerGUI/Application/CMakeFiles/ElmerGUI.dir/cad/cadview.cpp.o                                                                                   
[ 63%] Building CXX object ElmerGUI/Application/CMakeFiles/ElmerGUI.dir/ElmerGUI_autogen/mocs_compilation.cpp.o                                                             
In file included from /home/gary/Elmer/build/ElmerGUI/Application/ElmerGUI_autogen/mocs_compilation.cpp:2:
/home/gary/Elmer/build/ElmerGUI/Application/ElmerGUI_autogen/45M7AGRP2H/moc_axes.cpp:15:2: error: #error "This file was generated using the moc from 5.11.3. It"
 #error "This file was generated using the moc from 5.11.3. It"
  ^~~~~
/home/gary/Elmer/build/ElmerGUI/Application/ElmerGUI_autogen/45M7AGRP2H/moc_axes.cpp:16:2: error: #error "cannot be used with the include files from this version of Qt."
 #error "cannot be used with the include files from this version of Qt."
  ^~~~~
/home/gary/Elmer/build/ElmerGUI/Application/ElmerGUI_autogen/45M7AGRP2H/moc_axes.cpp:17:2: error: #error "(The moc has changed too much.)"
 #error "(The moc has changed too much.)"
 
 
I have my system set with qt5 default. Removing ElmerGUI from the CmakeLists.txt file doesn't help. I just get a series of other errors. If additional information would be helpful, please ask.

Any help will be sincerely appreciated


Gary R
kevinarden
Posts: 2237
Joined: 25 Jan 2019, 01:28
Antispam: Yes

Re: make problems

Post by kevinarden »

I had this a few releases ago. Just delete the scripts/kconfig/qconf.moc file (or rename if if you want to keep a backup). The make xconfig script then generates a new one that is compatible
Gary R
Posts: 162
Joined: 12 Apr 2012, 07:23
Antispam: Yes
Location: Long Beach CA, USA

Re: make problems

Post by Gary R »

Hi all,
After looking around and reading a bit I finally fixed this. If you go into the CMakeLists.txt file and change the following code

Code: Select all

# Check if Fortran compiler supports contiguous keyword
INCLUDE(testContiguous)
IF(CMAKE_Fortran_COMPILER_SUPPORTS_CONTIGUOUS)
  ADD_DEFINITIONS(-DCONTIG=CONTIGUOUS) #Remove CONTIGUOUS or #the whole thing.
ELSE()
  ADD_DEFINITIONS(-DCONTIG=)
ENDIF()
at line 317 with my installation (no guarantee in that) the problem goes away. While this temporary fix works, we need a more permanent fix. How???

Thanks to the contributors to the Compilation fails at CRSMatrix.F90 post for pointing me in the correct direction.
Post Reply