-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
62 lines (42 loc) · 1.19 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
ERL = $(shell which erl)
ERLFLAGS= -pa $(CURDIR)/.eunit -pa $(CURDIR)/ebin -pa $(CURDIR)/*/ebin
REBAR=$(shell which rebar)
ifeq ($(REBAR),)
$(error "Rebar not available on this system")
endif
DEPSOLVER_PLT=$(CURDIR)/.depsolver_plt
DIALYZER_OPTS= -Wunmatched_returns -Werror_handling -Wrace_conditions
all: build
.PHONY: get-deps build-deps
$(DEPSOLVER_PLT):
-dialyzer --output_plt $(DEPSOLVER_PLT) --build_plt \
--apps erts kernel stdlib crypto public_key ssh ssl syntax_tools \
mnesia xmerl inets asn1
get-deps:
$(REBAR) g-d
build-deps:
$(REBAR) co
deps: get-deps build-deps
build:
$(REBAR) co skip_deps=true
eunit: build
$(REBAR) eunit skip_deps=true -v
ct:
cp src/* ebin/
$(REBAR) ct skip_deps=true -v
build-plt: $(DEPSOLVER_PLT) build
dialyzer: $(DEPSOLVER_PLT) build
-dialyzer --verbose --plt $(DEPSOLVER_PLT) $(DIALYZER_OPTS) -r ebin
typer: $(DEPSOLVER_PLT)
typer --plt $(DEPSOLVER_PLT) -r ./src -I ./include -I ./deps
edoc:
$(REBAR) doc skip_deps=true
clean:
$(REBAR) clean
distclean: clean
rm -f $(DEPSOLVER_PLT)
rm -rf $(CURDIR)/deps/
rm -rf $(CURDIR)/logs/
rm -rf $(CURDIR)/doc/
rm -rf $(CURDIR)/test/fakes3_SUITE_data/
precommit: distclean get-deps build-deps ct edoc