forked from Novartis/hdf5r
-
Notifications
You must be signed in to change notification settings - Fork 25
Open
Description
rhdf5 tries to run h5cc -show in its configure script, in order to determine the libraries to be used:
Line 125 in dc4774c
| HDF5_LIBS=`${H5CC} -show | ${GREP} -o " \-[lL][^[:space:]]\+" | tr "\n" " "` |
Unfortunately, this doesn't appear to be a supported option. I see:
$ /opt/homebrew/bin/h5cc -show
/opt/homebrew/h5cc
dir is /opt/homebrew
clang: error: unknown argument: '-show'
This is on macOS, with hdf5 1.14.4.3 installed from Homebrew. My guess is that the intention here is to read the variables reported via pkg-config, but those could also just be read by rhdf5 using pkg-config directly:
$ pkg-config --cflags --libs hdf5
-I/opt/homebrew/Cellar/hdf5/1.14.4.3/include -L/opt/homebrew/Cellar/hdf5/1.14.4.3/lib -lhdf5
For reference, this is the contents of my h5cc script, which is as-is from Homebrew:
#! /bin/sh
##
# Copyright by The HDF Group.
# All rights reserved.
#
# This file is part of HDF5. The full HDF5 copyright notice, including
# terms governing use, modification, and redistribution, is contained in
# the COPYING file, which can be found at the root of the source code
# distribution tree, or in https://www.hdfgroup.org/licenses.
# If you do not have access to either file, you may request a copy from
# help@hdfgroup.org.
##
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
prg=$dir/$(basename -- "$prg") || exit
printf '%s\n' "$prg"
printf 'dir is %s\n' "$dir"
# Show the configuration summary of the library recorded in the
# libhdf5.settings file residing in the lib directory.
showconfigure()
{
cat $dir/lib/libhdf5.settings
status=$?
}
export PKG_CONFIG_PATH=$dir/lib/pkgconfig
for arg in $@ ; do
case "$arg" in
-showconfig)
showconfigure
exit $status
;;
*)
clang $@ `pkg-config --define-variable=prefix=$dir --cflags --libs hdf5`
status=$?
exit $status
;;
esac
done
It's possible that the issue here lies with Homebrew, since as far as I can see the h5cc source script is quite a bit more fully-featured...
Metadata
Metadata
Assignees
Labels
No labels