-
Notifications
You must be signed in to change notification settings - Fork 20
/
Makefile
36 lines (26 loc) · 883 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
PROJECT = elli_websocket
REBAR := $(shell which rebar 2>/dev/null || echo ./rebar)
REBAR_URL := https://github.com/downloads/basho/rebar/rebar
DIALYZER = dialyzer
all: compile
./rebar:
erl -noshell -s inets start -s ssl start \
-eval '{ok, saved_to_file} = httpc:request(get, {"$(REBAR_URL)", []}, [], [{stream, "./rebar"}])' \
-s inets stop -s init stop
chmod +x ./rebar
compile: rebar
$(REBAR) compile
test: rebar
$(REBAR) -C rebar.test.config get-dep compile
$(REBAR) -C rebar.test.config eunit -v skip_deps=true
clean: rebar
$(REBAR) clean
distclean:
rm $(REBAR)
# dializer
build-plt:
@$(DIALYZER) --build_plt --output_plt .$(PROJECT).plt \
--apps erts kernel stdlib crypto public_key ssl -r deps
dialyze:
@$(DIALYZER) -pa deps/*/ebin --src src --plt .$(PROJECT).plt --no_native \
-Werror_handling -Wrace_conditions -Wunmatched_returns