Commit 244eb270 authored by Thomas Jahns's avatar Thomas Jahns 🤸
Browse files

Rename NETCDF_LDFLAGS to NETCDF_LIBS and substitute it in pkgconfig file.

parent c5d8fabb
......@@ -192,7 +192,7 @@ MANIFEST_TOOL = @MANIFEST_TOOL@
MKDIR_P = @MKDIR_P@
NC_CONFIG = @NC_CONFIG@
NETCDF_INCLUDE = @NETCDF_INCLUDE@
NETCDF_LDFLAGS = @NETCDF_LDFLAGS@
NETCDF_LIBS = @NETCDF_LIBS@
NM = @NM@
NMEDIT = @NMEDIT@
OBJDUMP = @OBJDUMP@
......
......@@ -170,7 +170,7 @@ MANIFEST_TOOL = @MANIFEST_TOOL@
MKDIR_P = @MKDIR_P@
NC_CONFIG = @NC_CONFIG@
NETCDF_INCLUDE = @NETCDF_INCLUDE@
NETCDF_LDFLAGS = @NETCDF_LDFLAGS@
NETCDF_LIBS = @NETCDF_LIBS@
NM = @NM@
NMEDIT = @NMEDIT@
OBJDUMP = @OBJDUMP@
......
......@@ -41,7 +41,7 @@
"include" : "@HDF5_INCLUDE@"
},
"netcdf" : {
"lib" : "@NETCDF_LDFLAGS@",
"lib" : "@NETCDF_LIBS@",
"include" : "@NETCDF_INCLUDE@"
},
"grip_api" : {
......
......@@ -648,9 +648,9 @@ ENABLE_GRIB
GRIB_API_INCLUDE
GRIB_API_LDFLAGS
JASPER_LDFLAGS
NETCDF_LIBS
NETCDF_INCLUDE
NC_CONFIG
NETCDF_LDFLAGS
HDF5_LIBS
HDF5_INCLUDE
HDF5_ROOT
......@@ -25136,6 +25136,7 @@ fi
# ----------------------------------------------------------------------
# Compile application with netcdf
NETCDF_INCLUDE=''
NETCDF_LIBS=''
 
# Check whether --with-netcdf was given.
if test "${with_netcdf+set}" = set; then :
......@@ -25218,8 +25219,7 @@ else
as_fn_error $? "Could not link to netcdf library" "$LINENO" 5
fi
 
NETCDF_LDFLAGS=" -lnetcdf"
NETCDF_LIBS=" -lnetcdf"
# Extract the first word of "nc-config", so it can be a program name with args.
set dummy nc-config; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
......@@ -25362,8 +25362,7 @@ else
as_fn_error $? "Could not link to netcdf library" "$LINENO" 5
fi
 
NETCDF_LDFLAGS=" -L$NETCDF_ROOT/lib -lnetcdf"
NETCDF_LIBS=" -L$NETCDF_ROOT/lib -lnetcdf"
NETCDF_INCLUDE=" -I$NETCDF_ROOT/include"
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking nc-config script" >&5
$as_echo_n "checking nc-config script... " >&6; }
......@@ -25451,6 +25450,7 @@ $as_echo "suppressed" >&6; }
fi
 
 
# ----------------------------------------------------------------------
# Link application with JASPER library (needed for GRIB2 compression)
 
......
......@@ -199,7 +199,7 @@ MANIFEST_TOOL = @MANIFEST_TOOL@
MKDIR_P = @MKDIR_P@
NC_CONFIG = @NC_CONFIG@
NETCDF_INCLUDE = @NETCDF_INCLUDE@
NETCDF_LDFLAGS = @NETCDF_LDFLAGS@
NETCDF_LIBS = @NETCDF_LIBS@
NM = @NM@
NMEDIT = @NMEDIT@
OBJDUMP = @OBJDUMP@
......
......@@ -18,15 +18,15 @@ noinst_PROGRAMS += CdiInfo
noinst_LTLIBRARIES += libcdipp.la
endif
#
locallibs = $(top_builddir)/src/.libs/libcdi.so @LTLIBOBJS@ @NETCDF_LDFLAGS@ @HDF5_LIBS@ @SZLIB_LIBS@ @ZLIB_LIBS@
locallibs = $(top_builddir)/src/.libs/libcdi.so @LTLIBOBJS@ @NETCDF_LIBS@ @HDF5_LIBS@ @SZLIB_LIBS@ @ZLIB_LIBS@
libcdipp_la_SOURCES = cdi.cpp cdi.hpp
libcdipp_la_LIBADD = $(top_builddir)/src/libcdi.la
libcdipp_la_LDFLAGS = @NETCDF_LDFLAGS@ @HDF5_LIBS@ @SZLIB_LIBS@ @ZLIB_LIBS@ $(LDFLAGS)
libcdipp_la_LDFLAGS = @NETCDF_LIBS@ @HDF5_LIBS@ @SZLIB_LIBS@ @ZLIB_LIBS@ $(LDFLAGS)
CdiInfo_SOURCES = CdiInfo.cpp
CdiInfo_LDADD = libcdipp.la
CdiInfo_LDFLAGS = @NETCDF_LDFLAGS@ @HDF5_LIBS@ @SZLIB_LIBS@ @ZLIB_LIBS@ $(LDFLAGS)
CdiInfo_LDFLAGS = @NETCDF_LIBS@ @HDF5_LIBS@ @SZLIB_LIBS@ @ZLIB_LIBS@ $(LDFLAGS)
#
#
if ENABLE_RUBY
......
......@@ -187,7 +187,7 @@ MANIFEST_TOOL = @MANIFEST_TOOL@
MKDIR_P = @MKDIR_P@
NC_CONFIG = @NC_CONFIG@
NETCDF_INCLUDE = @NETCDF_INCLUDE@
NETCDF_LDFLAGS = @NETCDF_LDFLAGS@
NETCDF_LIBS = @NETCDF_LIBS@
NM = @NM@
NMEDIT = @NMEDIT@
OBJDUMP = @OBJDUMP@
......@@ -289,13 +289,13 @@ EXTRA_DIST = $(SWIGCDIOBJ) $(SWIGCDILIB) ruby/cdilib_wrap.c \
python/testObj.py
noinst_LTLIBRARIES = $(am__append_3)
#
locallibs = $(top_builddir)/src/.libs/libcdi.so @LTLIBOBJS@ @NETCDF_LDFLAGS@ @HDF5_LIBS@ @SZLIB_LIBS@ @ZLIB_LIBS@
locallibs = $(top_builddir)/src/.libs/libcdi.so @LTLIBOBJS@ @NETCDF_LIBS@ @HDF5_LIBS@ @SZLIB_LIBS@ @ZLIB_LIBS@
libcdipp_la_SOURCES = cdi.cpp cdi.hpp
libcdipp_la_LIBADD = $(top_builddir)/src/libcdi.la
libcdipp_la_LDFLAGS = @NETCDF_LDFLAGS@ @HDF5_LIBS@ @SZLIB_LIBS@ @ZLIB_LIBS@ $(LDFLAGS)
libcdipp_la_LDFLAGS = @NETCDF_LIBS@ @HDF5_LIBS@ @SZLIB_LIBS@ @ZLIB_LIBS@ $(LDFLAGS)
CdiInfo_SOURCES = CdiInfo.cpp
CdiInfo_LDADD = libcdipp.la
CdiInfo_LDFLAGS = @NETCDF_LDFLAGS@ @HDF5_LIBS@ @SZLIB_LIBS@ @ZLIB_LIBS@ $(LDFLAGS)
CdiInfo_LDFLAGS = @NETCDF_LIBS@ @HDF5_LIBS@ @SZLIB_LIBS@ @ZLIB_LIBS@ $(LDFLAGS)
#
AM_CPPFLAGS = -I$(top_srcdir)/src
#
......
......@@ -136,6 +136,7 @@ AC_SUBST([HDF5_LIBS])
# ----------------------------------------------------------------------
# Compile application with netcdf
NETCDF_INCLUDE=''
NETCDF_LIBS=''
AC_ARG_WITH([netcdf],
[AS_HELP_STRING([--with-netcdf=<yes|no|directory> (default=yes)],[location of netcdf library (lib and include subdirs)])],
[AS_CASE(["$with_netcdf"],
......@@ -146,7 +147,7 @@ AC_ARG_WITH([netcdf],
[netcdf],
[AC_DEFINE([HAVE_LIBNETCDF],[1],[Define to 1 for NETCDF support])],
[AC_MSG_ERROR([Could not link to netcdf library])])
AC_SUBST([NETCDF_LDFLAGS],[" -lnetcdf"])
NETCDF_LIBS=" -lnetcdf"
AC_CHECK_PROG(NC_CONFIG,nc-config,nc-config)
AS_IF([test "x$NC_CONFIG" != "x"],
[AC_MSG_CHECKING([netcdf's nc2 support])
......@@ -167,7 +168,7 @@ AC_ARG_WITH([netcdf],
[netcdf],
[AC_DEFINE([HAVE_LIBNETCDF],[1],[Define to 1 for NETCDF support])],
[AC_MSG_ERROR([Could not link to netcdf library])])
AC_SUBST([NETCDF_LDFLAGS],[" -L$NETCDF_ROOT/lib -lnetcdf"])
NETCDF_LIBS=" -L$NETCDF_ROOT/lib -lnetcdf"
NETCDF_INCLUDE=" -I$NETCDF_ROOT/include"
AC_MSG_CHECKING([nc-config script])
AC_CHECK_PROG(NC_CONFIG,nc-config,[$NETCDF_ROOT/bin/nc-config],,["$NETCDF_ROOT/bin"])
......@@ -187,6 +188,7 @@ AC_ARG_WITH([netcdf],
[AC_MSG_CHECKING([for NETCDF library])
AC_MSG_RESULT([suppressed])])
AC_SUBST([NETCDF_INCLUDE])
AC_SUBST([NETCDF_LIBS])
# ----------------------------------------------------------------------
# Link application with JASPER library (needed for GRIB2 compression)
AC_ARG_WITH([jasper],
......
......@@ -193,7 +193,7 @@ MANIFEST_TOOL = @MANIFEST_TOOL@
MKDIR_P = @MKDIR_P@
NC_CONFIG = @NC_CONFIG@
NETCDF_INCLUDE = @NETCDF_INCLUDE@
NETCDF_LDFLAGS = @NETCDF_LDFLAGS@
NETCDF_LIBS = @NETCDF_LIBS@
NM = @NM@
NMEDIT = @NMEDIT@
OBJDUMP = @OBJDUMP@
......
......@@ -4,7 +4,7 @@ libdir=@libdir@
includedir=@includedir@
cflags=-I@includedir@
fcflags=@FPP_INCOPT@@includedir@ @CDI_F90_INTERFACE_FCFLAGS@
libs=-L@libdir@ -lcdi @GRIB_API_LDFLAGS@ @JASPER_LDFLAGS@ @NETCDF_LDFLAGS@ @HDF5_LIBS@ @SZLIB_LIBS@ @ZLIB_LIBS@ @THREADS_LIBS@
libs=-L@libdir@ -lcdi @GRIB_API_LDFLAGS@ @JASPER_LDFLAGS@ @NETCDF_LIBS@ @HDF5_LIBS@ @SZLIB_LIBS@ @ZLIB_LIBS@ @THREADS_LIBS@
netcdf_root=@NETCDF_ROOT@
threads_libs=@THREADS_LIBS@
threads_cflags=@THREADS_INCLUDE@
......@@ -16,6 +16,7 @@ hdf5_root=@HDF5_ROOT@
hdf5_cflags=@HDF5_INCLUDE@
hdf5_libs=@HDF5_LIBS@
netcdf_cflags=@NETCDF_INCLUDE@
netcdf_libs=@NETCDF_LIBS@
Name: @PACKAGE_NAME@
Description: CDI is an Interface to access Climate and NWP model Data.
......
......@@ -156,7 +156,7 @@ MANIFEST_TOOL = @MANIFEST_TOOL@
MKDIR_P = @MKDIR_P@
NC_CONFIG = @NC_CONFIG@
NETCDF_INCLUDE = @NETCDF_INCLUDE@
NETCDF_LDFLAGS = @NETCDF_LDFLAGS@
NETCDF_LIBS = @NETCDF_LIBS@
NM = @NM@
NMEDIT = @NMEDIT@
OBJDUMP = @OBJDUMP@
......
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