]> arthur.barton.de Git - netdata.git/commitdiff
build: move warning to autoconf
authorAlon Bar-Lev <alon.barlev@gmail.com>
Sun, 15 Nov 2015 23:15:48 +0000 (01:15 +0200)
committerAlon Bar-Lev <alon.barlev@gmail.com>
Sun, 15 Nov 2015 23:15:50 +0000 (01:15 +0200)
all customization/warning/interaction should be at autoconf level

compile time is too late.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
configure.ac
src/storage_number.c
src/web_client.c

index ed32a935dab3d741f042fbe106d620fca8d42a54..c8a28297d40b54f6c917cc306ce21f36022a128a 100644 (file)
@@ -155,3 +155,6 @@ AC_CONFIG_FILES([
        web/Makefile
 ])
 AC_OUTPUT
+
+test "${with_math}" != "yes" && AC_MSG_WARN([You are building without math. math allows accurate calculations. It should be enabled.])
+test "${with_zlib}" != "yes" && AC_MSG_WARN([You are building without zlib. zlib allows netdata to trasnfer a lot less data with web clients. It should be enabled.])
index 823619e61f6dadd9d31f646d8c4b9806eb012123..fe8e4f1f70e6be8b6f6922cadf0445e2a712cb6a 100755 (executable)
@@ -3,8 +3,6 @@
 #endif
 #ifdef STORAGE_WITH_MATH
 #include <math.h>
-#else
-#warning "You are building without math. math allows accurate calculations. It should be enabled."
 #endif
 
 #include "common.h"
index 0e18f7ac589d5286c245b67049263d92e0bb19f7..48fd47be4bd51cec3ab9edbc6637ec9eb64b64b7 100755 (executable)
@@ -229,8 +229,6 @@ void web_client_reset(struct web_client *w)
 
 #ifdef NETDATA_WITH_ZLIB
        if(likely(w->zoutput)) sent = (long)w->zstream.total_out;
-#else
-#warning "You are building without zlib. zlib allows netdata to trasnfer a lot less data with web clients. It should be enabled."
 #endif
 
        long size = (w->mode == WEB_CLIENT_MODE_FILECOPY)?w->data->rbytes:w->data->bytes;