[petsc-users] Configure/make with "--download-hdf5" or "--with-hdf5-dir=" crashes

Åsmund Ervik asmund.ervik at ntnu.no
Mon Sep 1 03:22:50 CDT 2014


Hi,

When I try to configure PETSc with HDF5 by using "--download-hdf5", I
get a very long error message from PETSc compiling HDF5 (see attached
error-down-hdf5.tar.gz) which boils down to

h5tools_str.c: In function 'h5tools_str_indent':
h5tools_str.c:635:1: error: expected expression before '/' token

This happens both with PETSc 3.5.1 and 3.4.5. It appears this was an
error in HDF5 version 1.8.10, cf.
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=711777


Subsequently I installed HDF5 v. 1.8.12 using my OS package manager and
then tried to configure with "--with-hdf5
--with-hdf5-dir=/path/to/system/hdf5" using PETSc 3.5.1. This time both
configure and make were successful, but "make test" fails with loads of
undefined references to PETSc HDF5 stuff (see below). configure.log and
make.log attached also for this case (error-with-hdf5.tar.gz)


If you need any more info, just ask :)

Regards,
Åsmund


Using PETSC_DIR=/opt/petsc/optim_gfortran and PETSC_ARCH=linux
*******************Error detected during compile or link!*******************
See http://www.mcs.anl.gov/petsc/documentation/faq.html
/opt/petsc/optim_gfortran/src/snes/examples/tutorials ex19
*********************************************************************************
/opt/petsc/optim_gfortran/linux/bin/mpicc -o ex19.o -c -fPIC -Wall
-Wwrite-strings -Wno-strict-aliasing -Wno-unknown-pragmas -O3
-march=native   -I/opt/petsc/optim_gfortran/include
-I/opt/petsc/optim_gfortran/linux/include -I/usr/include    `pwd`/ex19.c
/opt/petsc/optim_gfortran/linux/bin/mpicc -fPIC -Wall -Wwrite-strings
-Wno-strict-aliasing -Wno-unknown-pragmas -O3 -march=native  -o ex19
ex19.o -Wl,-rpath,/opt/petsc/optim_gfortran/linux/lib
-L/opt/petsc/optim_gfortran/linux/lib  -lpetsc
-Wl,-rpath,/opt/petsc/optim_gfortran/linux/lib -lHYPRE
-Wl,-rpath,/usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.0
-L/usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.0 -lmpichcxx -lstdc++
-lsuperlu_4.3 -lflapack -lfblas -lparmetis -lmetis -lX11 -lpthread -lssl
-lcrypto -Wl,-rpath,/usr/lib -L/usr/lib -lhdf5_hl -lhdf5 -lm -lmpichf90
-lgfortran -lm -lgfortran -lm -lquadmath -lm -lmpichcxx -lstdc++ -ldl
-lmpich -lopa -lmpl -lrt -lpthread -lgcc_s -ldl
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5GetFileId'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5PushGroup'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5PopGroup'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerCreate_HDF5'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5ReadAttribute'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5WriteAttribute'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5SetTimestep'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PETSC_VIEWER_HDF5_'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5HasAttribute'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5GetTimestep'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5GetGroup'
collect2: error: ld returned 1 exit status
makefile:108: recipe for target 'ex19' failed
make[3]: [ex19] Error 1 (ignored)
/usr/bin/rm -f ex19.o
*******************Error detected during compile or link!*******************
See http://www.mcs.anl.gov/petsc/documentation/faq.html
/opt/petsc/optim_gfortran/src/snes/examples/tutorials ex5f
*********************************************************
/opt/petsc/optim_gfortran/linux/bin/mpif90 -c  -fPIC  -Wall
-Wno-unused-variable -ffree-line-length-0 -Wno-unused-dummy-argument -O3
-march=native -fno-protect-parens -fstack-arrays
-I/opt/petsc/optim_gfortran/include
-I/opt/petsc/optim_gfortran/linux/include -I/usr/include    -o ex5f.o ex5f.F
/opt/petsc/optim_gfortran/linux/bin/mpif90 -fPIC  -Wall
-Wno-unused-variable -ffree-line-length-0 -Wno-unused-dummy-argument -O3
-march=native -fno-protect-parens -fstack-arrays  -o ex5f ex5f.o
-Wl,-rpath,/opt/petsc/optim_gfortran/linux/lib
-L/opt/petsc/optim_gfortran/linux/lib  -lpetsc
-Wl,-rpath,/opt/petsc/optim_gfortran/linux/lib -lHYPRE
-Wl,-rpath,/usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.0
-L/usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.0 -lmpichcxx -lstdc++
-lsuperlu_4.3 -lflapack -lfblas -lparmetis -lmetis -lX11 -lpthread -lssl
-lcrypto -Wl,-rpath,/usr/lib -L/usr/lib -lhdf5_hl -lhdf5 -lm -lmpichf90
-lgfortran -lm -lgfortran -lm -lquadmath -lm -lmpichcxx -lstdc++ -ldl
-lmpich -lopa -lmpl -lrt -lpthread -lgcc_s -ldl
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5GetFileId'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5PushGroup'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5PopGroup'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerCreate_HDF5'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5ReadAttribute'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5WriteAttribute'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5SetTimestep'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PETSC_VIEWER_HDF5_'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5HasAttribute'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5GetTimestep'
/opt/petsc/optim_gfortran/linux/lib/libpetsc.so: undefined reference to
`PetscViewerHDF5GetGroup'
collect2: error: ld returned 1 exit status
makefile:50: recipe for target 'ex5f' failed


-------------- next part --------------
A non-text attachment was scrubbed...
Name: error-with-hdf5.tar.gz
Type: application/gzip
Size: 329211 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20140901/6ed45d01/attachment-0002.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: error-down-hdf5.tar.gz
Type: application/gzip
Size: 446573 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20140901/6ed45d01/attachment-0003.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 473 bytes
Desc: OpenPGP digital signature
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20140901/6ed45d01/attachment-0001.pgp>


More information about the petsc-users mailing list