forked from HdrHistogram/hdr_histogram_erl
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
63 lines (48 loc) · 1.31 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
REBAR=$(shell [ -f ./rebar ] && echo "./rebar" || echo "rebar" )
CC=$(shell clang -v >/dev/null && echo "clang" || echo "gcc")
.PHONY: all erl test clean doc
all: test perf
build:
$(REBAR) get-deps compile
buildplt:
if [ ! -f .plt ]; then \
dialyzer --build_plt --output_plt .plt --apps kernel stdlib ; \
fi
pltclean:
@rm .plt
dialyze:
@ERL_LIBS=deps dialyzer --fullpath -Wno_undefined_callbacks \
--plts .plt \
-r ebin --src src \
| grep -v -f ./dialyzer.ignore-warnings
test: build
$(REBAR) skip_deps=true ct
eqc: build
$(REBAR) skip_deps=true eunit
clean:
$(REBAR) clean
-rm -f doc/*.md doc/edoc-info
-rm -rvf deps ebin .eunit
perf: build
$(CC) -ggdb -c -O3 -ffast-math -std=c99 -I c_src perf/hh.c -o perf/hh.o
$(CC) -ggdb -lm -o perf/hh c_src/hdr_histogram.o perf/hh.o
perf/hh 1000000 1000000 1
perf/hh 100000000 1000000 1
perf/hh 1000000000 1000000 1
perf/hh 1000000 1000000 3
perf/hh 100000000 1000000 3
perf/hh 1000000000 1000000 3
perf/hh 1000000 1000000 5
perf/hh 100000000 1000000 5
perf/hh 1000000000 1000000 5
doc: build
$(REBAR) doc
demo-elixir: doc
elixir -pa ebin -r examples/simple.exs -e "Simple.main"
demo-lfe: doc
ERL_LIBS=deps:.. lfescript examples/simple.lfe
demo-erlang: doc
./examples/simple.erl
eqc-compile: build
-mkdir ebin
erl -make