diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2007-06-11 08:39:23 +0000 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2007-06-11 08:39:23 +0000 |
commit | f87e084925dec6b82734cd2dc44695633b0c3ee5 (patch) | |
tree | 200133b2bdf86d45f5fe9fb0470a3b94151f7ccc | |
parent | 81378442ff2a89b20595ee52a25b21383df7bf9d (diff) | |
download | rsyslog-f87e084925dec6b82734cd2dc44695633b0c3ee5.tar.gz rsyslog-f87e084925dec6b82734cd2dc44695633b0c3ee5.tar.xz rsyslog-f87e084925dec6b82734cd2dc44695633b0c3ee5.zip |
some more fixes for FEATURE_KLOGD mechanism
-rw-r--r-- | freebsd/Makefile | 2 | ||||
-rw-r--r-- | klogd.c | 7 | ||||
-rw-r--r-- | linux/Makefile | 9 | ||||
-rw-r--r-- | master.make | 6 |
4 files changed, 17 insertions, 7 deletions
diff --git a/freebsd/Makefile b/freebsd/Makefile index 2170544f..22d674e3 100644 --- a/freebsd/Makefile +++ b/freebsd/Makefile @@ -75,7 +75,7 @@ MANDIR = /usr/share/man .endif .if $(FEATURE_KLOGD) == 1 - WITHDB=-DWITH_KLOGD + FEATKLOGD=-DFEATURE_KLOGD .endif .if $(FEATURE_NETZIP) == 1 @@ -19,7 +19,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -#ifdef WITH_KLOGD +#ifdef FEATURE_KLOGD /* * Steve Lord (lord@cray.com) 7th Nov 92 * @@ -1170,11 +1170,12 @@ int main(argc, argv) } } } -#else /* #ifdef WITH_KLOGD */ +#else /* #ifdef FEATURE_KLOGD */ #include <stdio.h> -void main() +int main() { fprintf(stderr, "FEATURE_KLOGD was disabled during this build, so klogd is not available.\n"); + return(1); } #endif /* #ifdef WITH_KLOGD */ /* diff --git a/linux/Makefile b/linux/Makefile index 75d68507..39ea440c 100644 --- a/linux/Makefile +++ b/linux/Makefile @@ -41,6 +41,11 @@ FEATURE_RFC3195=0 # Enable multithreading via pthreads (experimental!) FEATURE_PTHREADS=1 +# This feature indicates if klogd functionality +# should be integrated. If it is switched off, klogd +# is still compiled, but it is an empty shell. +FEATURE_KLOGD=1 + # Enable debug mode (much slower code) FEATURE_DEBUG=0 @@ -72,6 +77,10 @@ ifeq ($(strip $(FEATURE_DB)), 1) WITHDB=-DWITH_DB endif +ifeq ($(strip $(FEATURE_KLOGD)), 1) + FEATKLOGD=-DFEATURE_KLOGD +endif + ifeq ($(strip $(FEATURE_REGEXP)), 1) F_REGEXP=-DFEATURE_REGEXP endif diff --git a/master.make b/master.make index 0ddc450e..d8d2e506 100644 --- a/master.make +++ b/master.make @@ -66,13 +66,13 @@ syslog.o: syslog.c ${CC} ${CFLAGS} ${SYSLOG_FLAGS} -c $(VPATH)syslog.c klogd.o: klogd.c klogd.h version.h - ${CC} ${CFLAGS} ${KLOGD_FLAGS} $(DEB) -c $(VPATH)klogd.c + ${CC} ${CFLAGS} ${KLOGD_FLAGS} ${FEATKLOGD} $(DEB) -c $(VPATH)klogd.c ksym.o: ksym.c klogd.h - ${CC} ${CFLAGS} ${KLOGD_FLAGS} -c $(VPATH)ksym.c + ${CC} ${CFLAGS} ${KLOGD_FLAGS} ${FEATKLOGD} -c $(VPATH)ksym.c ksym_mod.o: ksym_mod.c klogd.h - ${CC} ${CFLAGS} ${KLOGD_FLAGS} -c $(VPATH)ksym_mod.c + ${CC} ${CFLAGS} ${KLOGD_FLAGS} ${FEATKLOGD} -c $(VPATH)ksym_mod.c clean: rm -f *.o *.log *~ *.orig syslogd rfc3195d |