summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure27
1 files changed, 27 insertions, 0 deletions
diff --git a/configure b/configure
index 1e7bd517..44b5ed3b 100755
--- a/configure
+++ b/configure
@@ -100,6 +100,7 @@ have_quilt=
have_patch=
have_unistd=
have_timegm=
+have_syslog=
need_svid_source=
need_bsd_source=
@@ -573,6 +574,9 @@ compiler_prefix := $compiler_prefix
# prefix for non-compiler toolchain commands
tool_prefix := $tool_prefix
+# do we compile in syslog support?
+have_syslog := $have_syslog
+
# do we compile in debug support?
debug_support := $debug_support
@@ -1406,6 +1410,29 @@ else
have_unistd=y
fi
+printf "Checking for syslog ... "
+
+cat > conftest.c <<!
+#include <syslog.h>
+
+int main(void)
+{
+ openlog("foo", LOG_CONS, LOG_DAEMON);
+ syslog(LOG_EMERG, "bar %d\n", 3);
+ setlogmask(0);
+ closelog();
+ return 0;
+}
+!
+rm -f conftest
+if ! $make conftest > conftest.err 2>&1 || ! [ -x conftest ] ; then
+ printf "no\n"
+else
+ printf "yes\n"
+ printf "#define HAVE_SYSLOG 1\n" >> config.h
+ have_syslog=y
+fi
+
#
# Dependent variables
#