[Opendnssec-commits] [keihatsu.kirei.se/svn/dnssec] r5302 - in trunk/softHSM: . src/lib

Rickard Bellgrim rickard at opendnssec.org
Fri Jul 8 11:52:27 CEST 2011


Author: rb
Date: 2011-07-08 11:52:26 +0200 (Fri, 08 Jul 2011)
New Revision: 5302

Modified:
   trunk/softHSM/configure.ac
   trunk/softHSM/src/lib/log.cpp
Log:
For now, disable logging on Windows


Modified: trunk/softHSM/configure.ac
===================================================================
--- trunk/softHSM/configure.ac	2011-07-08 07:01:03 UTC (rev 5301)
+++ trunk/softHSM/configure.ac	2011-07-08 09:52:26 UTC (rev 5302)
@@ -78,7 +78,7 @@
 AC_SUBST([YIELD_LIB])
 
 AC_CHECK_FUNCS(getpassphrase)
-AC_CHECK_HEADERS([sys/time.h dlfcn.h pthread.h], [], [],
+AC_CHECK_HEADERS([sys/time.h dlfcn.h pthread.h syslog.h], [], [],
   [[#ifdef HAVE_DLFCN_H
   #include <dlfcn.h>
   #endif

Modified: trunk/softHSM/src/lib/log.cpp
===================================================================
--- trunk/softHSM/src/lib/log.cpp	2011-07-08 07:01:03 UTC (rev 5301)
+++ trunk/softHSM/src/lib/log.cpp	2011-07-08 09:52:26 UTC (rev 5302)
@@ -32,22 +32,33 @@
 *
 ************************************************************/
 
+#include "log.h"
+#include "config.h"
+
+#ifdef HAVE_SYSLOG_H
 #include <syslog.h>
+#endif
 
-#include "log.h"
-
 void logError(const char *functionName, const char *text) {
+#ifdef HAVE_SYSLOG_H
   syslog(LOG_ERR, "SoftHSM: %s: %s", functionName, text);
+#endif
 }
 
 void logWarning(const char *functionName, const char *text) {
+#ifdef HAVE_SYSLOG_H
   syslog(LOG_WARNING, "SoftHSM: %s: %s", functionName, text);
+#endif
 }
 
 void logInfo(const char *functionName, const char *text) {
+#ifdef HAVE_SYSLOG_H
   syslog(LOG_INFO, "SoftHSM: %s: %s", functionName, text);
+#endif
 }
 
 void logDebug(const char *functionName, const char *text) {
+#ifdef HAVE_SYSLOG_H
   syslog(LOG_DEBUG, "SoftHSM: %s: %s", functionName, text);
+#endif
 }




More information about the Opendnssec-commits mailing list