Dear HDF5 users and Developers,
I'm currently struggling to compile an fortran application that contains
HDF5 functions with the Intel compiler suite 2016 on Ubuntu 14.04
What I did
1) Install MPICH using the Intel compilers
2) Install HDF5 using the Intel compilers with MPICH
3) Install PETSc using the MPICH compilers and telling PETSc where HDF5
is located
4) Trying to compile my application with the PETSc makefile. That
Fails
Doing the same with the current GNU compilers works fine.
Using openMPI instead of MPICH does not solve the problem, I also tried
it on different Linux flavors.
The (shortened) linker command looks like
mpif90 -Wl,-rpath,/opt//petsc-3.6.3/Intel-16.0-MPICH-3.2/lib
-Wl,-rpath,/opt//hdf5-1.8.16/Intel/16.0/MPICH/3.2/lib
-Wl,-rpath,/opt//szip-2.1/Intel/16.0/lib -lz
-L/opt//petsc-3.6.3/Intel-16.0-MPICH-3.2/lib
-L/opt//hdf5-1.8.16/Intel/16.0/MPICH/3.2/lib
-L/opt//szip-2.1/Intel/16.0/lib -fPIC -O3 -xHost -no-prec-div
-openmp -openmp-report0 -parallel -shared-intel -O2 -stand f08
-standard-semantics -O2 -o DAMASK_spectral.exe DAMASK_spectral.o \
prec.o DAMASK_interface.o IO.o HDF5_Utilities.o
-L/opt//petsc-3.6.3/Intel-16.0-MPICH-3.2/lib -lpetsc
-Wl,-rpath,/opt/petsc-3.6.3/Intel-16.0-MPICH-3.2/lib
-L/opt/petsc-3.6.3/Intel-16.0-MPICH-3.2/lib -lsuperlu_4.3
-lsuperlu_dist_4.1 -lcmumps -ldmumps -lsmumps -lzmumps -lmumps_common
-lpord -lscalapack -lHYPRE
-Wl,-rpath,/opt/fftw-3.3.4/Intel/16.0/MPICH/3.2/lib
-L/opt/fftw-3.3.4/Intel/16.0/MPICH/3.2/lib
-Wl,-rpath,/opt/hdf5-1.8.16/Intel/16.0/MPICH/3.2/lib
-L/opt/hdf5-1.8.16/Intel/16.0/MPICH/3.2/lib
-Wl,-rpath,/opt/szip-2.1/Intel/16.0/lib -L/opt/szip-2.1/Intel/16.0/lib
-Wl,-rpath,/opt/mpich-3.2/Intel/16.0/lib -L/opt/mpich-3.2/Intel/16.0/lib
-Wl,-rpath,/opt/intel/compilers_and_libraries_2016/linux/mkl/lib/intel64
-L/opt/intel/compilers_and_libraries_2016/linux/mkl/lib/intel64
-Wl,-rpath,/opt/intel/compilers_and_libraries_2016/linux/lib/intel64
-L/opt/intel/compilers_and_libraries_2016/linux/lib/intel64
-Wl,-rpath,/opt/intel/compilers_and_libraries_2016.0.109/linux/compiler/lib/intel64_lin -L/opt/intel/compilers_and_libraries_2016.0.109/linux/compiler/lib/intel64_lin -Wl,-rpath,/usr/lib/gcc/x86_64-linux-gnu/5 -L/usr/lib/gcc/x86_64-linux-gnu/5 -Wl,-rpath,/usr/lib/x86_64-linux-gnu -L/usr/lib/x86_64-linux-gnu -Wl,-rpath,/lib/x86_64-linux-gnu -L/lib/x86_64-linux-gnu -lmpicxx -lumfpack -lklu -lcholmod -lbtf -lccolamd -lcolamd -lcamd -lamd -lsuitesparseconfig -lml -lmpicxx -llapack -lblas -lparmetis -lmetis -lhdf5hl_fortran -lhdf5_fortran -lhdf5_hl -lhdf5 -lfftw3_mpi -lfftw3 -lpthread -lhwloc -lchaco -lmpifort -lifport -lifcore_pic -lm -lpthread -lm -lmpicxx -lz -Wl,-rpath,/opt/petsc-3.6.3/Intel-16.0-MPICH-3.2/lib -L/opt/petsc-3.6.3/Intel-16.0-MPICH-3.2/lib -Wl,-rpath,/opt/fftw-3.3.4/Intel/16.0/MPICH/3.2/lib -L/opt/fftw-3.3.4/Intel/16.0/MPICH/3.2/lib -Wl,-rpath,/opt/hdf5-1.8.16/Intel/16.0/MPICH/3.2/lib -L/opt/hdf5-1.8.16/Intel/16.0/MPICH/3.2/lib -Wl,-rpath,/opt/szip-2.1/Intel/16.0/lib -L/opt/szip-2.1/Intel/16.0/lib -ldl -Wl,-rpath,/opt/mpich-3.2/Intel/16.0/lib -L/opt/mpich-3.2/Intel/16.0/lib -lmpi -Wl,-rpath,/opt/petsc-3.6.3/Intel-16.0-MPICH-3.2/lib -L/opt/petsc-3.6.3/Intel-16.0-MPICH-3.2/lib -Wl,-rpath,/opt/fftw-3.3.4/Intel/16.0/MPICH/3.2/lib -L/opt/fftw-3.3.4/Intel/16.0/MPICH/3.2/lib -Wl,-rpath,/opt/hdf5-1.8.16/Intel/16.0/MPICH/3.2/lib
So I'm linking in the correct order against the 4 libraries from HDF5
and have the Path given with -L and even as -Wl,rpath.
However, I get a bunch of these messages:
/nethome/storage/raid4/m.diehl/DAMASK/code/HDF5_Utilities.f90:58:
undefined reference to `h5lib_MP_h5open_f_'
even though the verbose compiler command
-Wl,--verbose
tells that it finds the libraries:
attempt to
open /opt//hdf5-1.8.16/Intel/16.0/MPICH/3.2/lib/libhdf5hl_fortran.so
succeeded
-lhdf5hl_fortran
(/opt//hdf5-1.8.16/Intel/16.0/MPICH/3.2/lib/libhdf5hl_fortran.so)
readelf -
···
--
------------------------------------------------
Max-Planck-Institut für Eisenforschung GmbH
Max-Planck-Straße 1
D-40237 Düsseldorf
Handelsregister B 2533
Amtsgericht Düsseldorf
Geschäftsführung
Prof. Dr. Gerhard Dehm
Prof. Dr. Jörg Neugebauer
Prof. Dr. Dierk Raabe
Dr. Kai de Weldige
Ust.-Id.-Nr.: DE 11 93 58 514
Steuernummer: 105 5891 1000
-------------------------------------------------
Please consider that invitations and e-mails of our institute are
only valid if they end with …@mpie.de.
If you are not sure of the validity please contact rco@mpie.de
Bitte beachten Sie, dass Einladungen zu Veranstaltungen und E-Mails
aus unserem Haus nur mit der Endung …@mpie.de gültig sind.
In Zweifelsfällen wenden Sie sich bitte an rco@mpie.de
-------------------------------------------------