then
with_libcurl="no ($with_curl_config failed)"
else
- SAVE_CFLAGS=$CFLAGS
- CFLAGS="$CFLAGS $with_curl_cflags"
+ SAVE_CPPFLAGS="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS $with_curl_cflags"
AC_CHECK_HEADERS(curl/curl.h, [], [with_libcurl="no (curl/curl.h not found)"], [])
- CFLAGS="$SAVE_CFLAGS"
+ CPPFLAGS="$SAVE_CPPFLAGS"
fi
fi
if test "x$with_libcurl" = "xyes"
then
with_libmysql="no"
else
- SAVE_CFLAGS=$CFLAGS
- CFLAGS="$CFLAGS $with_mysql_cflags"
+ SAVE_CPPFLAGS="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS $with_mysql_cflags"
AC_CHECK_HEADERS(mysql/mysql.h, [], [with_libmysql="no (mysql/mysql.h not found)"], [])
- CFLAGS="$SAVE_CFLAGS"
+ CPPFLAGS="$SAVE_CPPFLAGS"
fi
fi
if test "x$with_libmysql" = "xyes"
then
with_libnetsnmp="no ($with_snmp_config failed)"
else
- SAVE_CFLAGS=$CFLAGS
- CFLAGS="$CFLAGS $with_snmp_cflags"
+ SAVE_CPPFLAGS="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS $with_snmp_cflags"
AC_CHECK_HEADERS(net-snmp/net-snmp-config.h, [], [with_libnetsnmp="no (net-snmp/net-snmp-config.h not found)"])
- CFLAGS="$SAVE_CFLAGS"
+ CPPFLAGS="$SAVE_CPPFLAGS"
fi
fi
if test "x$with_libnetsnmp" = "xyes"
fi
if test "x$with_libupsclient" = "xyes"
then
- SAVE_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $with_upsclient_cflags"
+ SAVE_CPPFLAGS="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS $with_upsclient_cflags"
AC_CHECK_HEADERS(upsclient.h, [], [with_libupsclient="no (upsclient.h not found)"])
- CFLAGS="$SAVE_CFLAGS"
+ CPPFLAGS="$SAVE_CPPFLAGS"
fi
if test "x$with_libupsclient" = "xyes"
then
fi
if test "x$with_libupsclient" = "xyes"
then
+ SAVE_CPPFLAGS="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS $with_upsclient_cflags"
+
AC_CHECK_TYPES([UPSCONN_t, UPSCONN], [], [],
[#include <stdlib.h>
#include <stdio.h>
#include <upsclient.h>])
+
+ CPPFLAGS="$SAVE_CPPFLAGS"
fi
AM_CONDITIONAL(BUILD_WITH_LIBUPSCLIENT, test "x$with_libupsclient" = "xyes")