storage default directory from config.mk

This commit is contained in:
Jan-Piet Mens
2015-09-10 12:17:14 +02:00
parent c4f836ceb3
commit 1bd44d1562
5 changed files with 9 additions and 4 deletions
+4 -1
View File
@@ -27,6 +27,9 @@ ifeq ($(HAVE_HTTP),yes)
LIBS += -lssl
endif
CFLAGS += -DSTORAGEDEFAULT=\"$(STORAGEDEFAULT)\"
TARGETS += ot-recorder ocat ghashfind
@@ -59,7 +62,7 @@ http.o: http.c mongoose.h util.h http.h storage.h
util.o: util.c util.h Makefile config.mk
ghashfind.o: ghashfind.c util.h
mongoose.o: mongoose.c mongoose.h
ocat.o: ocat.c storage.h util.h
ocat.o: ocat.c storage.h util.h config.mk
storage.o: storage.c storage.h config.h util.h gcache.h
ghash2lmdb.o: ghash2lmdb.c gcache.h
+2
View File
@@ -2,6 +2,8 @@
HAVE_HTTP ?= yes
HAVE_LMDB ?= yes
STORAGEDEFAULT = "./store"
# Optionally specify the path to the Mosquitto libs, include here
MOSQUITTO_INC = -I/usr/include
MOSQUITTO_LIB = -L/usr/lib
+1 -1
View File
@@ -140,7 +140,7 @@ void usage(char *prog)
printf(" --fields tst,lat,lon,... Choose fields for CSV. (dflt: ALL)\n");
printf(" --last -L JSON object with last users\n");
printf(" --killdata requires -u and -d\n");
printf(" --storage -S storage dir (./store)\n");
printf(" --storage -S storage dir (%s)\n", STORAGEDEFAULT);
printf(" --norevgeo -G disable ghash to reverge-geo lookups\n");
printf(" --precision ghash precision (dflt: %d)\n", GEOHASH_PREC);
printf("\n");
+1 -1
View File
@@ -685,7 +685,7 @@ void usage(char *prog)
{
printf("Usage: %s [options..] topic [topic ...]\n", prog);
printf(" --help -h this message\n");
printf(" --storage -S storage dir (./store)\n");
printf(" --storage -S storage dir (%s)\n", STORAGEDEFAULT);
printf(" --norevgeo -G disable ghash to reverge-geo lookups\n");
printf(" --skipdemo -D do not handle objects with _demo\n");
printf(" --useretained -R process retained messages (default: no)\n");
+1 -1
View File
@@ -38,7 +38,7 @@
#include "util.h"
#include "udata.h"
char STORAGEDIR[BUFSIZ] = "./store";
char STORAGEDIR[BUFSIZ] = STORAGEDEFAULT;
#define LINESIZE 8192