diff options
-rw-r--r-- | freebsd/Makefile | 7 | ||||
-rw-r--r-- | linux/Makefile | 4 | ||||
-rw-r--r-- | rfc3195d.c | 11 |
3 files changed, 20 insertions, 2 deletions
diff --git a/freebsd/Makefile b/freebsd/Makefile index a42edd08..27b2dac7 100644 --- a/freebsd/Makefile +++ b/freebsd/Makefile @@ -28,6 +28,9 @@ FEATURE_DB=1 # Enable regular expressions FEATURE_REGEXP=1 +# Enable RFC 3195 support (REQUIRES LIBLOGGING 0.6.0 or above!) +FEATURE_RFC3195=0 + # Enable debug mode (much slower code) FEATURE_DEBUG=0 @@ -55,6 +58,10 @@ MANDIR = /usr/share/man F_REGEXP=-DFEATURE_REGEXP .endif +.if $(FEATURE_RFC3195) == 1 + F_RFC3195=-DFEATURE_RFC3195 +.endif + .if $(FEATURE_DEBUG) == 0 DBG=-DNDEBUG .endif diff --git a/linux/Makefile b/linux/Makefile index 4ec862f4..7b8da0a8 100644 --- a/linux/Makefile +++ b/linux/Makefile @@ -31,10 +31,10 @@ FEATURE_DB=0 FEATURE_REGEXP=1 # Enable RFC 3195 support (REQUIRES LIBLOGGING 0.6.0 or above!) -FEATURE_RFC3195=1 +FEATURE_RFC3195=0 # Enable debug mode (much slower code) -FEATURE_DEBUG=1 +FEATURE_DEBUG=0 ############################################################# # END OF USER SETTINGS # @@ -26,6 +26,16 @@ */ #include <stdio.h> +#ifndef FEATURE_RFC3195 +/* this is a trick: if RFC3195 is not to be supported, we just do an + * error message. + */ +int main() +{ + fprintf(stderr, "error: not compiled with FEATURE_RFC3195 - terminating.\n"); + return(1); +} +#else #include <unistd.h> #include <signal.h> #include <sys/socket.h> @@ -236,6 +246,7 @@ int main(int argc, char* argv[]) srAPIExitLib(pAPI); return 0; } +#endif /* #ifndef FEATURE_RFC3195 - main wrapper */ /* * vi:set ai: |