Commit 939e6805 authored by Thomas Jahns's avatar Thomas Jahns 🤸
Browse files

Add HDF5_ROOT variable to substitutions in pkgconfig file.

parent a9eec05d
......@@ -170,6 +170,7 @@ GRIB_API_INCLUDE = @GRIB_API_INCLUDE@
GRIB_API_LDFLAGS = @GRIB_API_LDFLAGS@
HDF5_INCLUDE = @HDF5_INCLUDE@
HDF5_LIBS = @HDF5_LIBS@
HDF5_ROOT = @HDF5_ROOT@
HOST_NAME = @HOST_NAME@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
......
......@@ -148,6 +148,7 @@ GRIB_API_INCLUDE = @GRIB_API_INCLUDE@
GRIB_API_LDFLAGS = @GRIB_API_LDFLAGS@
HDF5_INCLUDE = @HDF5_INCLUDE@
HDF5_LIBS = @HDF5_LIBS@
HDF5_ROOT = @HDF5_ROOT@
HOST_NAME = @HOST_NAME@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
......
......@@ -653,6 +653,7 @@ NETCDF_INCLUDE
NETCDF_LDFLAGS
HDF5_LIBS
HDF5_INCLUDE
HDF5_ROOT
SZLIB_LIBS
SZLIB_INCLUDE
ZLIB_LIBS
......@@ -24815,6 +24816,7 @@ fi
 
# ----------------------------------------------------------------------
# Link application with HDF5 library, required for netcdf4
HDF5_ROOT=''
HDF5_INCLUDE=''
HDF5_LIBS=''
 
......@@ -24966,9 +24968,9 @@ else
fi
;; #(
*) :
HDF5_ROOT=$with_hdf5
if test -d "$HDF5_ROOT"; then :
LDFLAGS="-L$HDF5_ROOT/lib $LDFLAGS"
if test -d "$with_hdf5"; then :
HDF5_ROOT="$with_hdf5"
LDFLAGS="-L$HDF5_ROOT/lib $LDFLAGS"
CPPFLAGS="-I$HDF5_ROOT/include $CPPFLAGS"
for ac_header in hdf5.h
do :
......@@ -25115,8 +25117,8 @@ else
fi
HDF5_INCLUDE=" -I$HDF5_ROOT/include"
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: $HDF5_ROOT is not a directory! HDF5 suppressed" >&5
$as_echo "$as_me: $HDF5_ROOT is not a directory! HDF5 suppressed" >&6;}
{ $as_echo "$as_me:${as_lineno-$LINENO}: $with_hdf5 is not a directory! HDF5 suppressed" >&5
$as_echo "$as_me: $with_hdf5 is not a directory! HDF5 suppressed" >&6;}
fi ;; #(
*) :
;;
......@@ -25130,6 +25132,7 @@ fi
 
 
 
# ----------------------------------------------------------------------
# Compile application with netcdf
 
......
......@@ -177,6 +177,7 @@ GRIB_API_INCLUDE = @GRIB_API_INCLUDE@
GRIB_API_LDFLAGS = @GRIB_API_LDFLAGS@
HDF5_INCLUDE = @HDF5_INCLUDE@
HDF5_LIBS = @HDF5_LIBS@
HDF5_ROOT = @HDF5_ROOT@
HOST_NAME = @HOST_NAME@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
......
......@@ -165,6 +165,7 @@ GRIB_API_INCLUDE = @GRIB_API_INCLUDE@
GRIB_API_LDFLAGS = @GRIB_API_LDFLAGS@
HDF5_INCLUDE = @HDF5_INCLUDE@
HDF5_LIBS = @HDF5_LIBS@
HDF5_ROOT = @HDF5_ROOT@
HOST_NAME = @HOST_NAME@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
......
......@@ -84,6 +84,7 @@ AC_SUBST([SZLIB_INCLUDE])
AC_SUBST([SZLIB_LIBS])
# ----------------------------------------------------------------------
# Link application with HDF5 library, required for netcdf4
HDF5_ROOT=''
HDF5_INCLUDE=''
HDF5_LIBS=''
AC_ARG_WITH([hdf5],
......@@ -105,9 +106,9 @@ AC_ARG_WITH([hdf5],
[HDF5_LIBS=" -lhdf5_hl -lhdf5"],
[HDF5_LIBS=" -lhdf5"])
],
[*],[HDF5_ROOT=$with_hdf5
AS_IF([test -d "$HDF5_ROOT"],
[LDFLAGS="-L$HDF5_ROOT/lib $LDFLAGS"
[*],[AS_IF([test -d "$with_hdf5"],
[HDF5_ROOT="$with_hdf5"
LDFLAGS="-L$HDF5_ROOT/lib $LDFLAGS"
CPPFLAGS="-I$HDF5_ROOT/include $CPPFLAGS"
AC_CHECK_HEADERS([hdf5.h])
AC_SEARCH_LIBS([H5Fopen],
......@@ -126,9 +127,10 @@ AC_ARG_WITH([hdf5],
[HDF5_LIBS=" -L$HDF5_ROOT/lib -lhdf5_hl -lhdf5"],
[HDF5_LIBS=" -L$HDF5_ROOT/lib -lhdf5"])
HDF5_INCLUDE=" -I$HDF5_ROOT/include"],
[AC_MSG_NOTICE([$HDF5_ROOT is not a directory! HDF5 suppressed])])])],
[AC_MSG_NOTICE([$with_hdf5 is not a directory! HDF5 suppressed])])])],
[AC_MSG_CHECKING([for hdf5 library])
AC_MSG_RESULT([suppressed])])
AC_SUBST([HDF5_ROOT])
AC_SUBST([HDF5_INCLUDE])
AC_SUBST([HDF5_LIBS])
# ----------------------------------------------------------------------
......
......@@ -171,6 +171,7 @@ GRIB_API_INCLUDE = @GRIB_API_INCLUDE@
GRIB_API_LDFLAGS = @GRIB_API_LDFLAGS@
HDF5_INCLUDE = @HDF5_INCLUDE@
HDF5_LIBS = @HDF5_LIBS@
HDF5_ROOT = @HDF5_ROOT@
HOST_NAME = @HOST_NAME@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
......
......@@ -12,6 +12,7 @@ zlib_cflags=@ZLIB_INCLUDE@
zlib_libs=@ZLIB_LIBS@
szlib_cflags=@SZLIB_INCLUDE@
szlib_libs=@SZLIB_LIBS@
hdf5_root=@HDF5_ROOT@
hdf5_cflags=@HDF5_INCLUDE@
hdf5_libs=@HDF5_LIBS@
......
......@@ -134,6 +134,7 @@ GRIB_API_INCLUDE = @GRIB_API_INCLUDE@
GRIB_API_LDFLAGS = @GRIB_API_LDFLAGS@
HDF5_INCLUDE = @HDF5_INCLUDE@
HDF5_LIBS = @HDF5_LIBS@
HDF5_ROOT = @HDF5_ROOT@
HOST_NAME = @HOST_NAME@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment