Bug 767589

Summary: openmpi, mpich2 builds of hdf5 lack static libraries
Product: [Fedora] Fedora EPEL Reporter: Jonathon Anderson <jonathon.anderson>
Component: hdf5Assignee: Orion Poplawski <orion>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: el6CC: orion, pertusus
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: hdf5-1.8.5.patch1-7.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-10-17 03:02:40 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Jonathon Anderson 2011-12-14 12:57:20 UTC
Description of problem:

Plain hdf5 is packages as three main packages.

* hdf5
* hdf5-static
* hdf5-devel

There are hdf5 packages built against mpich2 and openmpi, as well.  However, these builds lack static libraries.

* hdf5-openmpi
* hdf5-openmpi-devel
* hdf5-mpich2
* hdf5-mpich2-devel

None of these packages include static (.a) libraries, so static binaries cannot be built against them.

fen3:~/ParaView-3.12.0/build$ make
[  0%] Built target vtksys[  1%] Built target vtkzlib[  1%] Built target H5detect
[...]
[ 32%] Built target vtkXdmf
Linking CXX executable ../../../../bin/XdmfTestHDFMPI
../../../../bin/libXdmf.so: undefined reference to `H5Pcreate'
[...]

Version-Release number of selected component (if applicable):

hdf5-openmpi-devel-1.8.5.patch1-5.el6.x86_64
hdf5-openmpi-1.8.5.patch1-5.el6.x86_64

How reproducible:

Constant.

Steps to Reproduce:
1. Install hdf5-openmpi and hdf5-openmpi-devel
2. Try to compile something linking against hdf5 using the openmpi compiler wrapper (ParaView, in our case)
  
Actual results:

Linking CXX executable ../../../../bin/XdmfTestHDFMPI
../../../../bin/libXdmf.so: undefined reference to `H5Pcreate'
[...]

Expected results:

Compile succeeds.

Comment 1 Orion Poplawski 2011-12-14 17:21:13 UTC
I don't quite see how this is an hdf5 issue.  Presumably libXdfm.so needs to be linked against hdf5 but isn't, but I don't see why it can't be linked against the shared library.

Comment 2 Jonathon Anderson 2011-12-17 06:03:04 UTC
> I don't see why it can't be linked against the shared library.

Can you link against a shared library statically?  I was under the impression that you cannot.

It's possible that this is mostly cmake's fault (either by design or configuration) in not picking up the shared library.  I admit that I don't know enough to make that call yet.

However, even without the failed link error message, there's still the asymmetry between the plain hdf5 packages and the mpi-linked variants.  I don't see any reason why static libraries should be included in one variant and not the other.