Top Page > Browsing
compilation error: openmx 3.8
Date: 2018/10/03 02:15
Name: Renato

Dear all,

I am having difficult in the installation of OpenMX 3.8.

I am loading the modules
1) fftw/3.3.7
2) mkl/18.0.2.199
3) openmpi/1.10.7
4) gnu/5.4.0

I am using

MKLROOT=/opt/intel/compilers_and_libraries_2018.2.199/linux/mkl
CC=mpicc -O3 -ffast-math -fopenmp -I/opt/ohpc/pub/libs/gnu/openmpi/fftw/3.3.7/include -I/$MKLROOT/include
FC=mpif90 -O3 -ffast-math -fopenmp -I/$(MKLROOT)/include
LIB= -L/opt/ohpc/pub/libs/gnu/openmpi/fftw/3.3.7/lib -lfftw3 -L/$MKLROOT/lib/intel64/ $(MKLROOT)/lib/intel64/libmkl_intel_lp64.a $(MKLROOT)/lib/intel64/libmkl_intel_thread.a $(MKLROOT)/lib/intel64/libmkl_core.a -lpthread -lgfortran

and obtaining

...
solve_evp_real.o solve_evp_complex.o NBO_Cluster.o NBO_Krylov.o exx.o exx_index.o exx_vector.o exx_log.o exx_step1.o exx_step2.o exx_file_overlap.o exx_file_eri.o exx_interface_openmx.o exx_debug.o exx_xc.o exx_rhox.o ./liberi-091216/source/eri.o ./liberi-091216/source/eri_ll.o ./liberi-091216/source/eri_sf.o ./liberi-091216/source/eri_interpolate.o ./liberi-091216/source/eri_gtbl.o ./liberi-091216/source/sbt/eri_sbt.o ./liberi-091216/source/sbt/log/eri_fsbt.o ./liberi-091216/source/sbt/log/eri_logfsbt.o ./liberi-091216/source/sbt/linear/eri_linfsbt.o -L/opt/ohpc/pub/libs/gnu/openmpi/fftw/3.3.7/lib -lfftw3 -L/KLROOT/lib/intel64/ /opt/intel/compilers_and_libraries_2018.2.199/linux/mkl/lib/intel64/libmkl_intel_lp64.a /opt/intel/compilers_and_libraries_2018.2.199/linux/mkl/lib/intel64/libmkl_intel_thread.a /opt/intel/compilers_and_libraries_2018.2.199/linux/mkl/lib/intel64/libmkl_core.a -lpthread -lgfortran -lm -o openmx
/usr/bin/ld: /opt/intel/compilers_and_libraries_2018.2.199/linux/mkl/lib/intel64/libmkl_core.a(mkl_semaphore.o): undefined reference to symbol 'dlsym@@GLIBC_2.2.5'
//usr/lib64/libdl.so.2: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
make: *** [openmx] Error 1

What must I change in the parameters CC, FC, and LIB to fix the problem?


Thanks in advance!
Renato

メンテ
Page: [1]

Re: compilation error: openmx 3.8 ( No.1 )
Date: 2018/10/03 11:12
Name: Mitsuaki Kawamura  <mkawamura@issp.u-tokyo.ac.jp>

Dear Renato

I think the following linker options should be appended at the end of "LIB".

-liomp5 -lm -ldl

Best regards,
Mitsuaki Kawamura
ISSP
メンテ
Re: compilation error: openmx 3.8 ( No.2 )
Date: 2018/10/03 12:59
Name: Renato

Dear Mitsuaki Kawamura,

Thank you for your replay.
When I apply your suggestion (inserting in LIB: -liomp5 -lm -ldl)

I obtain

/usr/bin/ld: cannot find -liomp5
collect2: error: ld returned 1 exit status
make: *** [openmx] Error 1

Please, would you have any adittional suggestion?

Thanks in advance.
Renato



メンテ
Re: compilation error: openmx 3.8 ( No.3 )
Date: 2018/10/03 13:52
Name: Naoya Yamaguchi

Dear Renato,

I guess that your compiler can't find the library "libiomp5", and in my knowledge, I think you don't necessarily need it if you use gcc (GNU C compiler). How about only adding "-ldl"?

Regards,
Naoya Yamaguchi
メンテ
Re: compilation error: openmx 3.8 ( No.4 )
Date: 2018/10/03 13:43
Name: Mitsuaki Kawamura  <mkawamura@issp.u-tokyo.ac.jp>

Dear Renato

Sorry, I missed you are using GNU compiler. In that case, it should be

-lgomp -lm -ldl

Best regards,
Mitsuaki Kawamura
ISSP
メンテ
Re: compilation error: openmx 3.8 ( No.5 )
Date: 2018/10/03 13:49
Name: Mitsuaki Kawamura  <mkawamura@issp.u-tokyo.ac.jp>

It seems strange.

Could you provide me the output of the following commands:

$ mpicc -show
$ mpif90 -show
$ ldd /opt/ohpc/pub/libs/gnu/openmpi/fftw/3.3.7/lib/libfftw3.so

Best regards,
Mitsuaki Kawamura
メンテ
Re: compilation error: openmx 3.8 ( No.6 )
Date: 2018/10/04 02:53
Name: Renato

Dear Mitsuaki Kawamura,

First of all, thank you for your support.

Adding -lgomp -lm -ldl the compilation still fails.

The outputs are:

$ mpicc -show
gcc -I/opt/ohpc/pub/mpi/openmpi-gnu/1.10.7/include -pthread -Wl,-rpath -Wl,/opt/ohpc/pub/mpi/openmpi-gnu/1.10.7/lib -Wl,--enable-new-dtags -L/opt/ohpc/pub/mpi/openmpi-gnu/1.10.7/lib -lmpi

$ mpif90 -show
gfortran -I/opt/ohpc/pub/mpi/openmpi-gnu/1.10.7/include -pthread -I/opt/ohpc/pub/mpi/openmpi-gnu/1.10.7/lib -Wl,-rpath -Wl,/opt/ohpc/pub/mpi/openmpi-gnu/1.10.7/lib -Wl,--enable-new-dtags -L/opt/ohpc/pub/mpi/openmpi-gnu/1.10.7/lib -lmpi_usempif08 -lmpi_usempi_ignore_tkr -lmpi_mpifh -lmpi

$ ldd /opt/ohpc/pub/libs/gnu/openmpi/fftw/3.3.7/lib/libfftw3.so
linux-vdso.so.1 => (0x00007ffd3ffc3000)
libm.so.6 => /lib64/libm.so.6 (0x00002abc3480e000)
libc.so.6 => /lib64/libc.so.6 (0x00002abc34b10000)
/lib64/ld-linux-x86-64.so.2 (0x00002abc342d9000)

Best regards,
Renato
メンテ
Re: compilation error: openmx 3.8 ( No.7 )
Date: 2018/10/04 03:01
Name: Renato

Dear Naoya Yamaguchi,

Thank you for your message.

Only adding -ldl the compilation fails.

The error starts with:

.o ./liberi-091216/source/sbt/log/eri_logfsbt.o ./liberi-091216/source/sbt/linear/eri_linfsbt.o -L/opt/ohpc/pub/libs/gnu/openmpi/fftw/3.3.7/lib -lfftw3 -L/KLROOT/lib/intel64/ /opt/intel/compilers_and_libraries_2018.2.199/linux/mkl/lib/intel64/libmkl_intel_lp64.a /opt/intel/compilers_and_libraries_2018.2.199/linux/mkl/lib/intel64/libmkl_intel_thread.a /opt/intel/compilers_and_libraries_2018.2.199/linux/mkl/lib/intel64/libmkl_core.a -lpthread -lgfortran -ldl -lm -o openmx
elpa1.o: In function `__elpa1_MOD_solve_tridi_single':
elpa1.f90:(.text+0x140): undefined reference to `mpi_abort_'
elpa1.o: In function `transform_columns.5186':
elpa1.f90:(.text+0x36e): undefined reference to `mpi_sendrecv_'
elpa1.f90:(.text+0x456): undefined reference to `mpi_sendrecv_'
elpa1.o: In function `resort_ev.5191':
elpa1.f90:(.text+0x7f0): undefined reference to `mpi_recv_'
elpa1.f90:(.text+0x917): undefined reference to `mpi_send_'
elpa1.o: In function `global_gather.5181':
elpa1.f90:(.text+0xb91): undefined reference to `mpi_allreduce_'
elpa1.f90:(.text+0xd5a): undefined reference to `mpi_sendrecv_replace_'
elpa1.f90:(.text+0xe20): undefined reference to `mpi_allreduce_'
elpa1.o: In function `check_monotony.5167':
elpa1.f90:(.text+0xf4c): undefined reference to `mpi_abort_'
elpa1.o: In function `__elpa1_MOD_merge_systems':
elpa1.f90:(.text+0x11b8): undefined reference to `mpi_comm_rank_'
elpa1.f90:(.text+0x11d2): undefined reference to `mpi_comm_size_'
elpa1.f90:(.text+0x11ec): undefined reference to `mpi_comm_rank_'
elpa1.f90:(.text+0x1206): undefined reference to `mpi_comm_size_'
elpa1.f90:(.text+0x30df): undefined reference to `mpi_allreduce_'
elpa1.f90:(.text+0x314b): undefined reference to `mpi_send_'
elpa1.f90:(.text+0x3187): undefined reference to `mpi_recv_'
elpa1.f90:(.text+0x55ac): undefined reference to `mpi_sendrecv_replace_'
elpa1.f90:(.text+0x5be0): undefined reference to `mpi_recv_'
elpa1.f90:(.text+0x5d48): undefined reference to `mpi_send_'
elpa1.f90:(.text+0x5db0): undefined reference to `mpi_allreduce_'
elpa1.o: In function `merge_recursive.6516':
.
.
.

Please, would you have any suggestion?

Best Regards,
Renato

メンテ
Re: compilation error: openmx 3.8 ( No.8 )
Date: 2018/10/04 11:01
Name: Mitsuaki Kawamura  <mkawamura@issp.u-tokyo.ac.jp>

Dear Renato

Thank you for sending.
Would you try the following setting ?

LIB= -L/opt/ohpc/pub/libs/gnu/openmpi/fftw/3.3.7/lib -lfftw3 -L${MKLROOT}/lib/intel64 -Wl,--no-as-needed -lmkl_intel_lp64 -lmkl_gnu_thread -lmkl_core -lmpi_usempif08 -lmpi_usempi_ignore_tkr -lmpi_mpifh -lgomp -lpthread -lm -ldl

Best regards,
Mitsuaki Kawamura
メンテ
Re: compilation error: openmx 3.8 ( No.9 )
Date: 2018/10/09 02:06
Name: Renato


Dear Mitsuaki Kawamura,

First of all, thank you for your support.

Using the setting you suggested:

LIB= -L/opt/ohpc/pub/libs/gnu/openmpi/fftw/3.3.7/lib -lfftw3 -L${MKLROOT}/lib/intel64 -Wl,--no-as-needed -lmkl_intel_lp64 -lmkl_gnu_thread -lmkl_core -lmpi_usempif08 -lmpi_usempi_ignore_tkr -lmpi_mpifh -lgomp -lpthread -lm -ldl

I obtained
:
:
ld: elpa1.o: undefined reference to symbol 'for_write_seq_fmt'
/opt/intel/compilers_and_libraries_2018.2.199/linux/compiler/lib/intel64/libifcoremt.so.5: error adding symbols: DSO missing from command line
make: *** [openmx] Error 1

Please, do you have any additional suggestion?

Best Regards,
Renato



メンテ
Re: compilation error: openmx 3.8 ( No.10 )
Date: 2018/10/09 03:38
Name: Naoya Yamaguchi

Dear Renato,

I think errors containing "for_write_seq_fmt" and "libifcoremt.so.5" is about the Intel compiler, but now you seems to use the GNU compiler.
So, I suspect that object files (.o) made from different compilers are mixed.
Could you try "make clean && make"?

Regards,
Naoya Yamaguchi
メンテ
Re: compilation error: openmx 3.8 ( No.11 )
Date: 2018/10/11 02:35
Name: Renato

Dear Naoya Yamaguchi,

Thank you for your message.

With your last tip, I was able to compile the code correctly.

Best Regards,
Renato
メンテ

Page: [1]

Thread Title (must) Move the thread to the top
Your Name (must)
E-Mail (must)
URL
Password (used in modification of the submitted text)
Comment (must)

   Save Cookie