Describe the bug
The compiler wrappers do the following calculation to find libhdf5.settings:
# Determine name and location of script
prg=$0
if [ ! -e "$prg" ]; then
case $prg in
(*/*) exit 1;;
(*) prg=$(command -v -- "$prg") || exit;;
esac
fi
dir=$(
cd -P -- "$(dirname -- "$prg")/.." && pwd -P
) || exit
prog_name=$(basename -- "$prg") || exit
prg=$dir/bin/$prog_name
prefix=$dir
libdir=$dir/@HDF5_INSTALL_LIB_DIR@
However this does not work when HDF5_INSTALL_BIN_DIR or HDF5_INSTALL_LIB_DIR are multiple levels. For the Fedora MPI builds we need to specify:
-DHDF5_INSTALL_LIB_DIR=%{_lib}/$mpi/lib \
-DHDF5_INSTALL_BIN_DIR=%{_lib}/$mpi/bin \
which results in /usr/lib64/mpich/bin/h5cc looking for /usr/lib64/mpich/lib64/mpich/lib/libhdf5.settings which is incorrect.
Expected behavior
h5cc finds libhdf5.settings
Platform (please complete the following information)
- HDF5 version 2.1.1
- OS and version
Fedora Rawhide
- Compiler and version
gcc 16
- Build system (e.g. CMake version) and generator (e.g. XCode, Ninja)
CMake
Describe the bug
The compiler wrappers do the following calculation to find libhdf5.settings:
However this does not work when HDF5_INSTALL_BIN_DIR or HDF5_INSTALL_LIB_DIR are multiple levels. For the Fedora MPI builds we need to specify:
which results in /usr/lib64/mpich/bin/h5cc looking for /usr/lib64/mpich/lib64/mpich/lib/libhdf5.settings which is incorrect.
Expected behavior
h5cc finds libhdf5.settings
Platform (please complete the following information)
Fedora Rawhide
gcc 16
CMake