mirror of
https://github.com/TREX-CoE/trexio.git
synced 2024-12-22 12:23:54 +01:00
If header is not found, try pkgconfig
This commit is contained in:
parent
aa4e9ca7d3
commit
5742221eb2
@ -134,11 +134,13 @@ AS_IF([test "x$with_hdf5" == "xno"], [
|
||||
HDF5_LIBS="-L$HDF5_PATH/lib -lhdf5"
|
||||
HDF5_CFLAGS="-I$HDF5_PATH/include"
|
||||
AC_DEFINE([HAVE_HDF5], 1, [Define to 1 if HDF5 is available]) ],
|
||||
[
|
||||
[ # else
|
||||
AC_CHECK_LIB([hdf5], [H5Fcreate], [ HDF5_LIBS="-lhdf5" ], [
|
||||
PKG_CHECK_MODULES([HDF5], [hdf5 >= 1.8])
|
||||
] )
|
||||
AC_CHECK_HEADER([hdf5.h], [HDF5_CFLAGS=""], [AC_MSG_ERROR([HDF5 header not found]) ])
|
||||
])
|
||||
AC_CHECK_HEADER([hdf5.h], [HDF5_CFLAGS=""], [
|
||||
[ PKG_CHECK_MODULES([HDF5], [hdf5 >= 1.8])
|
||||
])
|
||||
AC_DEFINE([HAVE_HDF5], 1, [Define to 1 if HDF5 is available])
|
||||
])
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user