forked from Feuerlabs/exometer
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
57 lines (40 loc) · 1.5 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
.PHONY: all clean clean_plt deps compile test doc dialyzer xref devnode_snmp_agent devnode_snmp_manager compile_examples ci
EXOMETER_PLT=exometer.plt
DIALYZER_OPTS = # -Wunderspecs
DIALYZER_APPS = erts kernel stdlib compiler syntax_tools snmp ssl ssh \
crypto public_key test_server webtool xmerl common_test \
lager goldrush afunix netlink folsom mnesia parse_trans \
setup exometer_core
all: deps compile
ci: compile xref dialyzer test
deps:
rebar get-deps
compile:
rebar compile
clean: clean_plt
rebar clean
clean-all: clean
rm -rf deps
test: compile_examples
ERL_LIBS=./examples rebar ct skip_deps=true
xref:
ERL_LIBS=./deps rebar xref skip_deps=true
edown_deps:
rebar get-deps compile edown=true
doc: edown_deps
rebar doc edown=true skip_deps=true
$(EXOMETER_PLT):
rebar get-deps compile
ERL_LIBS=deps dialyzer --build_plt --output_plt $(EXOMETER_PLT) \
--apps $(DIALYZER_APPS)
clean_plt:
rm -f $(EXOMETER_PLT)
dialyzer: deps compile $(EXOMETER_PLT)
dialyzer -r ebin --plt $(EXOMETER_PLT) $(DIALYZER_OPTS)
compile_examples:
erlc +'{parse_transform, lager_transform}' -pz deps/lager/ebin -I src -o examples/snmp_manager/ examples/snmp_manager/*.erl
devnode_snmp_agent:
erl -sname agent -pa deps/*/ebin ebin -config examples/snmp_agent/sys.config -boot start_sasl -s lager -s crypto -s exometer
devnode_snmp_manager: compile_examples
erl -sname manager -pz examples/snmp_manager -pz deps/*/ebin ebin -config examples/snmp_manager/sys.config \
-boot start_sasl -s lager -s crypto -s snmp