summaryrefslogtreecommitdiffstats
path: root/tests/profile/Makefile
diff options
context:
space:
mode:
authorCosta Tsaousis <costa@tsaousis.gr>2018-10-24 00:35:56 +0300
committerGitHub <noreply@github.com>2018-10-24 00:35:56 +0300
commit0a78758a111c10115de56b94dd152bf4cb505cec (patch)
tree890d58f880aebe796aa56b7ed5f9cf6f0c46e8c0 /tests/profile/Makefile
parentb85833f08135bb7b3c2a0001dac8742d1d62db91 (diff)
updated tests for the new hierarchy (#4464)
Diffstat (limited to 'tests/profile/Makefile')
-rw-r--r--tests/profile/Makefile51
1 files changed, 46 insertions, 5 deletions
diff --git a/tests/profile/Makefile b/tests/profile/Makefile
index 040219e6fd..5f4e8b5210 100644
--- a/tests/profile/Makefile
+++ b/tests/profile/Makefile
@@ -1,12 +1,53 @@
# SPDX-License-Identifier: GPL-3.0-or-later
-COMMON_CFLAGS=-I ../../src/ -I ../../
-PROFILE_CFLAGS=-O1 -ggdb -Wall -Wextra
+COMMON_CFLAGS = -I ../../ -DTARGET_OS=1 -Wall -Wextra
+PROFILE_CFLAGS = -O1 -ggdb $(COMMON_CFLAGS)
+PERFORMANCE_CFLAGS = -O2 $(COMMON_CFLAGS)
+
+CFLAGS = $(PERFORMANCE_CFLAGS)
+
+LIBNETDATA_FILES = \
+ ../../libnetdata/popen/popen.o \
+ ../../libnetdata/storage_number/storage_number.o \
+ ../../libnetdata/avl/avl.o \
+ ../../libnetdata/socket/socket.o \
+ ../../libnetdata/os.o \
+ ../../libnetdata/clocks/clocks.o \
+ ../../libnetdata/procfile/procfile.o \
+ ../../libnetdata/statistical/statistical.o \
+ ../../libnetdata/eval/eval.o \
+ ../../libnetdata/threads/threads.o \
+ ../../libnetdata/dictionary/dictionary.o \
+ ../../libnetdata/simple_pattern/simple_pattern.o \
+ ../../libnetdata/url/url.o \
+ ../../libnetdata/config/appconfig.o \
+ ../../libnetdata/libnetdata.o \
+ ../../libnetdata/buffer/buffer.o \
+ ../../libnetdata/adaptive_resortable_list/adaptive_resortable_list.o \
+ ../../libnetdata/locks/locks.o \
+ ../../libnetdata/log/log.o \
+ $(NULL)
+
+COMMON_LDFLAGS = $(LIBNETDATA_FILES) -pthread -lm
+
+all: statsd-stress benchmark-procfile-parser test-eval benchmark-dictionary benchmark-value-pairs
benchmark-procfile-parser: benchmark-procfile-parser.c
- gcc ${PROFILE_CFLAGS} ${COMMON_CFLAGS} -o $@ $^ ../../src/log.o ../../src/procfile.o ../../src/threads.o ../../src/locks.o ../../src/common.o ../../src/clocks.o ../../src/web_buffer.o ../../src/storage_number.o -pthread -lm
+ gcc ${CFLAGS} -o $@ $^ ${COMMON_LDFLAGS}
+
+benchmark-dictionary: benchmark-dictionary.c
+ gcc ${CFLAGS} -o $@ $^ ${COMMON_LDFLAGS}
+
+benchmark-value-pairs: benchmark-value-pairs.c
+ gcc ${CFLAGS} -o $@ $^ ${COMMON_LDFLAGS}
statsd-stress: statsd-stress.c
- gcc -O2 -Wall -Wextra -o $@ $^ -pthread
+ gcc ${CFLAGS} -o $@ $^ ${COMMON_LDFLAGS}
+
+test-eval: test-eval.c
+ gcc ${CFLAGS} -o $@ $^ ${COMMON_LDFLAGS}
+
+
+clean:
+ rm -f benchmark-procfile-parser statsd-stress test-eval benchmark-dictionary benchmark-value-pairs
-all: statsd-stress benchmark-procfile-parser