1
0
mirror of https://github.com/TREX-CoE/trexio.git synced 2024-12-22 20:35:44 +01:00

roll back names in PKG_CHECK_MODULES

This commit is contained in:
q-posev 2021-08-21 11:58:42 +03:00
parent 8b22494f2f
commit ed47bad056

View File

@ -50,6 +50,7 @@ AC_FC_LIBRARY_LDFLAGS
# pkg-config # pkg-config
PKG_PROG_PKG_CONFIG() PKG_PROG_PKG_CONFIG()
PKG_CFLAGS="" PKG_CFLAGS=""
PKG_LIBS=""
AC_PROG_INSTALL AC_PROG_INSTALL
AC_PROG_LIBTOOL AC_PROG_LIBTOOL
@ -95,16 +96,14 @@ LDFLAGS="${HDF5_LDFLAGS} ${LDFLAGS}"
LIBS="${HDF5_LIBS} ${LIBS}" LIBS="${HDF5_LIBS} ${LIBS}"
# Check if HDF5 is available with pkg-config. # Check if HDF5 is available with pkg-config.
# First argument has to be named differently than HDF5 (e.g. HDF5_MOD) because for pkg FOO
# PKG_CHECK_MODULES(FOO,...) sets FOO_LIBS but we have already used HDF5_LIBS above.
PKG_CHECK_MODULES([HDF5_MOD], [hdf5 >= 1.8], [ PKG_CHECK_MODULES([HDF5], [hdf5 >= 1.8], [
PKG_HDF5="hdf5" PKG_HDF5="hdf5"
],[ ],[
PKG_HDF5="" PKG_HDF5=""
]) ])
PKG_CFLAGS="${HDF5_MOD_CFLAGS}" PKG_CFLAGS="${HDF5_CFLAGS}"
PKG_LIBS="${HDF5_MOD_LIBS}" PKG_LIBS="${HDF5_LIBS}"
AC_SUBST([PKG_HDF5]) AC_SUBST([PKG_HDF5])
AC_SUBST([PKG_CFLAGS]) AC_SUBST([PKG_CFLAGS])