forked from zeromq/erlzmq2
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
44 lines (31 loc) · 792 Bytes
/
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
LINUX=$(shell uname | grep Linux | wc -l | xargs echo)
ifeq ($(LINUX),1)
ZMQ_FLAGS=--with-pic
else
ZMQ_FLAGS=
endif
ifndef ZEROMQ_VERSION
ZEROMQ_VERSION=v2.1.4
endif
all: perf
deps/zeromq2:
@mkdir -p deps
@git clone git://github.com/zeromq/zeromq2-1.git deps/zeromq2
@echo $(ZEROMQ_VERSION)
@cd deps/zeromq2 && git checkout $(ZEROMQ_VERSION)
deps/zeromq2/src/.libs/libzmq.a: deps/zeromq2
@cd deps/zeromq2 && ./autogen.sh && ./configure $(ZMQ_FLAGS) && make
dependencies: deps/zeromq2/src/.libs/libzmq.a
compile: dependencies
@./rebar compile
perf: compile
@cd perf && erlc erlzmq_perf.erl
test: compile
@./rebar eunit
docs:
@./rebar doc
bench: perf
@echo 'Running benchmarks, this could take some time...'
@mkdir -p graphs
@./perf/perfgraphs.py
@mv -f *.png graphs/