diff --git a/configure.ac b/configure.ac
index da332a9f76f6d0acd5a7e63ee66a843af9ccf3fc..86a697851df4d45303bfca2a4e62b95aece96c66 100644 (file)
--- a/configure.ac
+++ b/configure.ac
#include <linux/major.h>
#include <linux/types.h>
])
#include <linux/major.h>
#include <linux/types.h>
])
+ AC_CHECK_HEADERS([sys/sysmacros.h])
else
have_linux_raid_md_u_h="no"
fi
else
have_linux_raid_md_u_h="no"
fi
AM_CONDITIONAL(BUILD_WITH_LIBGCRYPT, test "x$with_libgcrypt" = "xyes")
# }}}
AM_CONDITIONAL(BUILD_WITH_LIBGCRYPT, test "x$with_libgcrypt" = "xyes")
# }}}
+# --with-libgps {{{
+with_libgps_cflags=""
+with_libgps_ldflags=""
+AC_ARG_WITH(libgps, [AS_HELP_STRING([--with-libgps@<:@=PREFIX@:>@], [Path to libgps.])],
+[
+ if test "x$withval" != "xno" && test "x$withval" != "xyes"
+ then
+ with_libgps_cflags="-I$withval/include"
+ with_libgps_ldflags="-L$withval/lib"
+ with_libgps="yes"
+ else
+ with_libgps="$withval"
+ fi
+],
+[
+ with_libgps="yes"
+])
+if test "x$with_libgps" = "xyes"
+then
+ SAVE_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS $with_libgps_cflags"
+
+ AC_CHECK_HEADERS(gps.h, [with_libgps="yes"], [with_libgps="no (gps.h not found)"])
+
+ CFLAGS="$SAVE_CFLAGS"
+fi
+if test "x$with_libgps" = "xyes"
+then
+ SAVE_CFLAGS="$CFLAGS"
+ SAVE_LDFLAGS="$LDFLAGS"
+ CFLAGS="$CFLAGS $with_libgps_cflags"
+ LDFLAGS="$LDFLAGS $with_libgps_ldflags"
+
+ AC_CHECK_LIB(gps, gps_open, [with_libgps="yes"], [with_libgps="no (symbol gps_open not found)"])
+
+ CFLAGS="$SAVE_CFLAGS"
+ LDFLAGS="$SAVE_LDFLAGS"
+fi
+if test "x$with_libgps" = "xyes"
+then
+ BUILD_WITH_LIBGPS_CFLAGS="$with_libgps_cflags"
+ BUILD_WITH_LIBGPS_LDFLAGS="$with_libgps_ldflags"
+ BUILD_WITH_LIBGPS_LIBS="-lgps"
+ AC_SUBST(BUILD_WITH_LIBGPS_CFLAGS)
+ AC_SUBST(BUILD_WITH_LIBGPS_LDFLAGS)
+ AC_SUBST(BUILD_WITH_LIBGPS_LIBS)
+fi
+AM_CONDITIONAL(BUILD_WITH_LIBGPS, test "x$with_libgps" = "xyes")
+# }}}
+
# --with-libgrpc++ {{{
with_libgrpcpp_cppflags=""
with_libgrpcpp_ldflags=""
# --with-libgrpc++ {{{
with_libgrpcpp_cppflags=""
with_libgrpcpp_ldflags=""
then
AC_LANG_PUSH(C++)
SAVE_CPPFLAGS="$CPPFLAGS"
then
AC_LANG_PUSH(C++)
SAVE_CPPFLAGS="$CPPFLAGS"
- CPPFLAGS="$with_libgrpcpp_cppflags $GRPCPP_CFLAGS $CPPFLAGS -std=c++11"
+ CPPFLAGS="-std=c++11 $with_libgrpcpp_cppflags $GRPCPP_CFLAGS $CPPFLAGS"
AC_CHECK_HEADERS([grpc++/grpc++.h], [],
[with_libgrpcpp="no (<grpc++/grpc++.h> not found)"]
)
AC_CHECK_HEADERS([grpc++/grpc++.h], [],
[with_libgrpcpp="no (<grpc++/grpc++.h> not found)"]
)
if test "x$with_libgrpcpp" = "xyes"
then
AC_LANG_PUSH(C++)
if test "x$with_libgrpcpp" = "xyes"
then
AC_LANG_PUSH(C++)
+ SAVE_CPPFLAGS="$CPPFLAGS"
SAVE_LDFLAGS="$LDFLAGS"
SAVE_LIBS="$LIBS"
SAVE_LDFLAGS="$LDFLAGS"
SAVE_LIBS="$LIBS"
+ CPPFLAGS="-std=c++11 $with_libgrpcpp_cppflags $GRPCPP_CFLAGS $CPPFLAGS"
LDFLAGS="$with_libgrpcpp_ldflags"
if test "x$GRPCPP_LIBS" = "x"
then
LDFLAGS="$with_libgrpcpp_ldflags"
if test "x$GRPCPP_LIBS" = "x"
then
],
[with_libgrpcpp="no (libgrpc++ not found)"]
)
],
[with_libgrpcpp="no (libgrpc++ not found)"]
)
+ CPPFLAGS="$SAVE_CPPFLAGS"
LDFLAGS="$SAVE_LDFLAGS"
LIBS="$SAVE_LIBS"
AC_LANG_POP(C++)
LDFLAGS="$SAVE_LDFLAGS"
LIBS="$SAVE_LIBS"
AC_LANG_POP(C++)
# --with-libpython {{{
AC_ARG_VAR([LIBPYTHON_CPPFLAGS], [Preprocessor flags for libpython])
AC_ARG_VAR([LIBPYTHON_LDFLAGS], [Linker flags for libpython])
# --with-libpython {{{
AC_ARG_VAR([LIBPYTHON_CPPFLAGS], [Preprocessor flags for libpython])
AC_ARG_VAR([LIBPYTHON_LDFLAGS], [Linker flags for libpython])
+AC_ARG_VAR([LIBPYTHON_LIBS], [Libraries for libpython])
AC_ARG_WITH([libpython],
[AS_HELP_STRING([--with-libpython],
AC_ARG_WITH([libpython],
[AS_HELP_STRING([--with-libpython],
if test $? -ne 0; then
with_libpython="no"
fi
if test $? -ne 0; then
with_libpython="no"
fi
+ LIBPYTHON_LIBS="`${PYTHON_CONFIG} --libs`"
+ if test $? -ne 0; then
+ with_libpython="no"
+ fi
fi
if test "$with_libpython" != "xno"; then
SAVE_CPPFLAGS="$CPPFLAGS"
SAVE_LDFLAGS="$LDFLAGS"
fi
if test "$with_libpython" != "xno"; then
SAVE_CPPFLAGS="$CPPFLAGS"
SAVE_LDFLAGS="$LDFLAGS"
+ SAVE_LIBS="$LIBS"
CPPFLAGS="$LIBPYTHON_CPPFLAGS $CPPFLAGS"
LDFLAGS="$LIBPYTHON_LDFLAGS $LDFLAGS"
CPPFLAGS="$LIBPYTHON_CPPFLAGS $CPPFLAGS"
LDFLAGS="$LIBPYTHON_LDFLAGS $LDFLAGS"
+ LIBS="$LIBPYTHON_LIBS $LIBS"
AC_CHECK_HEADERS([Python.h],
[
AC_MSG_CHECKING([for libpython])
AC_CHECK_HEADERS([Python.h],
[
AC_MSG_CHECKING([for libpython])
)
CPPFLAGS="$SAVE_CPPFLAGS"
LDFLAGS="$SAVE_LDFLAGS"
)
CPPFLAGS="$SAVE_CPPFLAGS"
LDFLAGS="$SAVE_LDFLAGS"
+ LIBS="$SAVE_LIBS"
fi
# }}} --with-libpython
fi
# }}} --with-libpython
[with_libnotify="no (pkg-config doesn't know libnotify)"]
)
[with_libnotify="no (pkg-config doesn't know libnotify)"]
)
-PKG_CHECK_MODULES([LIBRIEMANN_CLIENT], [riemann-client >= 1.8.0],
+PKG_CHECK_MODULES([LIBRIEMANN_CLIENT], [riemann-client >= 1.6.0],
[with_libriemann_client="yes"],
[with_libriemann_client="no (pkg-config doesn't know libriemann-client)"])
[with_libriemann_client="yes"],
[with_libriemann_client="no (pkg-config doesn't know libriemann-client)"])
plugin_ethstat="no"
plugin_fhcount="no"
plugin_fscache="no"
plugin_ethstat="no"
plugin_fhcount="no"
plugin_fscache="no"
+plugin_gps="no"
plugin_grpc="no"
plugin_interface="no"
plugin_ipmi="no"
plugin_grpc="no"
plugin_interface="no"
plugin_ipmi="no"
plugin_interface="yes"
fi
plugin_interface="yes"
fi
+if test "x$with_libgps" = "xyes"
+then
+ plugin_gps="yes"
+fi
+
if test "x$have_getloadavg" = "xyes"
then
plugin_load="yes"
if test "x$have_getloadavg" = "xyes"
then
plugin_load="yes"
AC_PLUGIN([filecount], [yes], [Count files in directories])
AC_PLUGIN([fscache], [$plugin_fscache], [fscache statistics])
AC_PLUGIN([gmond], [$with_libganglia], [Ganglia plugin])
AC_PLUGIN([filecount], [yes], [Count files in directories])
AC_PLUGIN([fscache], [$plugin_fscache], [fscache statistics])
AC_PLUGIN([gmond], [$with_libganglia], [Ganglia plugin])
+AC_PLUGIN([gps], [$plugin_gps], [GPS plugin])
AC_PLUGIN([grpc], [$plugin_grpc], [gRPC plugin])
AC_PLUGIN([hddtemp], [yes], [Query hddtempd])
AC_PLUGIN([interface], [$plugin_interface], [Interface traffic statistics])
AC_PLUGIN([grpc], [$plugin_grpc], [gRPC plugin])
AC_PLUGIN([hddtemp], [yes], [Query hddtempd])
AC_PLUGIN([interface], [$plugin_interface], [Interface traffic statistics])
AC_MSG_RESULT([ libesmtp . . . . . . $with_libesmtp])
AC_MSG_RESULT([ libganglia . . . . . $with_libganglia])
AC_MSG_RESULT([ libgcrypt . . . . . . $with_libgcrypt])
AC_MSG_RESULT([ libesmtp . . . . . . $with_libesmtp])
AC_MSG_RESULT([ libganglia . . . . . $with_libganglia])
AC_MSG_RESULT([ libgcrypt . . . . . . $with_libgcrypt])
+AC_MSG_RESULT([ libgps . . . . . . . $with_libgps])
AC_MSG_RESULT([ libgrpc++ . . . . . . $with_libgrpcpp])
AC_MSG_RESULT([ libhal . . . . . . . $with_libhal])
AC_MSG_RESULT([ libhiredis . . . . . $with_libhiredis])
AC_MSG_RESULT([ libgrpc++ . . . . . . $with_libgrpcpp])
AC_MSG_RESULT([ libhal . . . . . . . $with_libhal])
AC_MSG_RESULT([ libhiredis . . . . . $with_libhiredis])
AC_MSG_RESULT([ filecount . . . . . . $enable_filecount])
AC_MSG_RESULT([ fscache . . . . . . . $enable_fscache])
AC_MSG_RESULT([ gmond . . . . . . . . $enable_gmond])
AC_MSG_RESULT([ filecount . . . . . . $enable_filecount])
AC_MSG_RESULT([ fscache . . . . . . . $enable_fscache])
AC_MSG_RESULT([ gmond . . . . . . . . $enable_gmond])
+AC_MSG_RESULT([ gps . . . . . . . . . $enable_gps])
AC_MSG_RESULT([ grpc . . . . . . . . $enable_grpc])
AC_MSG_RESULT([ hddtemp . . . . . . . $enable_hddtemp])
AC_MSG_RESULT([ interface . . . . . . $enable_interface])
AC_MSG_RESULT([ grpc . . . . . . . . $enable_grpc])
AC_MSG_RESULT([ hddtemp . . . . . . . $enable_hddtemp])
AC_MSG_RESULT([ interface . . . . . . $enable_interface])