syslog.h
00001
00002
00003
00004 #ifndef _LIBU_SYSLOG_H_
00005 #define _LIBU_SYSLOG_H_
00006 #include <u/libu_conf.h>
00007 #include <stdarg.h>
00008
00009 #ifdef HAVE_SYSLOG
00010
00011 #include <syslog.h>
00012
00013 #else
00014
00015 #ifdef __cplusplus
00016 extern "C" {
00017 #endif
00018
00019
00020 #define LOG_EMERG 0
00021 #define LOG_ALERT 1
00022 #define LOG_CRIT 2
00023 #define LOG_ERR 3
00024 #define LOG_WARNING 4
00025 #define LOG_NOTICE 5
00026 #define LOG_INFO 6
00027 #define LOG_DEBUG 7
00028
00029
00030 #define LOG_KERN (0<<3)
00031 #define LOG_USER (1<<3)
00032 #define LOG_MAIL (2<<3)
00033 #define LOG_DAEMON (3<<3)
00034 #define LOG_AUTH (4<<3)
00035 #define LOG_SYSLOG (5<<3)
00036 #define LOG_LPR (6<<3)
00037 #define LOG_NEWS (7<<3)
00038 #define LOG_UUCP (8<<3)
00039 #define LOG_CRON (9<<3)
00040 #define LOG_AUTHPRIV (10<<3)
00041 #define LOG_FTP (11<<3)
00042 #define LOG_NETINFO (12<<3)
00043 #define LOG_REMOTEAUTH (13<<3)
00044 #define LOG_INSTALL (14<<3)
00045 #define LOG_LOCAL0 (16<<3)
00046 #define LOG_LOCAL1 (17<<3)
00047 #define LOG_LOCAL2 (18<<3)
00048 #define LOG_LOCAL3 (19<<3)
00049 #define LOG_LOCAL4 (20<<3)
00050 #define LOG_LOCAL5 (21<<3)
00051 #define LOG_LOCAL6 (22<<3)
00052 #define LOG_LOCAL7 (23<<3)
00053
00054 void syslog(int priority, const char *msg, ...);
00055 void vsyslog(int priority, const char *msg, va_list args);
00056
00057 #ifdef __cplusplus
00058 }
00059 #endif
00060
00061 #endif
00062
00063 #endif