Error during CalculiX installation (etime)


I have been trying to install CalculiX for some time now, by following the instructions given on

I know this is not a CalculiX forum, I tried asking the same question on
CalculiX mailing list but I have had no replies yet. But I am asking anyway, because I think there are some members here with experience of CaluliX.

When I make I am getting the following error:

gfortran -fopenmp -Wall -O3 -o bin/ccx_preCICE bin/ccx_2.15.o bin/ccx_2.15.a /home/prasad/SPOOLES.2.2//spooles.a -L/usr/local/lib -lprecice -lstdc++ -L/home/prasad/yaml-cpp-yaml-cpp-0.6.2//build -lyaml-cpp  /home/prasad/ARPACK//libarpack_INTEL.a -lpthread -lm -lc
/home/prasad/ARPACK//libarpack_INTEL.a(second.o): In function `second_':
second.f:(.text+0x14): undefined reference to `etime_'
collect2: error: ld returned 1 exit status
Makefile:101: recipe for target 'bin/ccx_preCICE' failed
make: *** [bin/ccx_preCICE] Error 1

I have tried changing line 24 in ARPACK/UTIL/second.f from EXTERNAL ETIME to * EXTERNAL ETIME, but I am still getting the same error.
I have also tried c EXTERNAL ETIME.

Can anyone think of a reason why this might be happening and how can I resolve it?

Thank you for your help.

@Alphaoo1 this could be compiler-specific. What is your gfortran --version? Can you easily try another one?

My gfortran version is GNU Fortran 7.5.0

Do I change the compiler version manually in the make file?
How do I use a different version?

Actually, don’t worry about the compiler version. Did you recompile ARPACK after you commented-out the EXTERNAL ETIME? Did you try running make clean first?

Indeed, this has nothing to do with preCICE and it barely has anything to do with CalculiX. It is specific to building a Fortran 77 code (ARPACK) in 2020. In any case, this file (ARPACK/UTIL/second.f) is only providing runtime measurements.

In any case, I do see that more preCICE users could run into this problem if they try to run one of our tutorials, as many of them use CalculiX for the solid side. So let’s document the solution here (and then add it to the wiki, where this is already mentioned)! :slight_smile:

1 Like

I did not recompile ARPACK after editing the second.f file.
But once I did, it worked.

Thanks a lot, Gerasimos.