From: Florian Forster Date: Sat, 25 Nov 2023 22:47:47 +0000 (+0100) Subject: gmond plugin: Look for RPC headers in /usr/include/tirpc. X-Git-Tag: 6.0.0-rc0~42^2~19 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3032dde118a3c5a586d051508d35a99514939c34;p=thirdparty%2Fcollectd.git gmond plugin: Look for RPC headers in /usr/include/tirpc. glibc removed the SunRPC headers, and the replacement headers are in a different location. Try and look for them there. --- diff --git a/configure.ac b/configure.ac index 5e30aee4c..de23fdd22 100644 --- a/configure.ac +++ b/configure.ac @@ -2649,6 +2649,25 @@ if test "x$with_libganglia" = "xyes"; then fi fi +AC_CHECK_HEADERS([rpc/types.h], + [have_rpc_types_h="yes"], + [have_rpc_types_h="no"] +) +AS_UNSET([ac_cv_header_rpc_types_h]) +if test "x$have_rpc_types_h" = "xno"; then + # SunRPC has been removed from glibc. + # Replacement headers are in the "tirpc" subdirectory. + SAVE_CPPFLAGS="$CPPFLAGS" + CPPFLAGS="$CPPFLAGS -I/usr/include/tirpc" + + AC_CHECK_HEADERS([rpc/types.h], + [GANGLIA_CPPFLAGS="$GANGLIA_CPPFLAGS -I/usr/include/tirpc"], + [with_libganglia="no (rpc/types.h not found)"] + ) + + CPPFLAGS="$SAVE_CPPFLAGS" +fi + SAVE_CPPFLAGS="$CPPFLAGS" SAVE_LDFLAGS="$LDFLAGS" CPPFLAGS="$CPPFLAGS $GANGLIA_CPPFLAGS"