-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
55 lines (44 loc) · 1.26 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
#
# Makefile
# =============================================================================
# Urban bus routing microservice prototype (Erlang/OTP port). Version 0.3.5
# =============================================================================
# An Erlang/OTP application, designed and intended to be run as a microservice,
# implementing a simple urban bus routing prototype.
# =============================================================================
# Copyright (C) 2022-2024 Radislav (Radicchio) Golubtsov
#
# (See the LICENSE file at the top of the source tree.)
#
# Profile: "default" or "prod".
PROF = prod
EBIN = _build/$(PROF)/lib/bus/ebin
BEAM = $(EBIN)/bus_app.beam \
$(EBIN)/bus_sup.beam
APPS = apps/bus/src
SRCS = $(APPS)/bus_app.erl \
$(APPS)/bus_sup.erl
SERV = _build/$(PROF)/rel/bus/lib
# Specify flags and other vars here.
REBAR3 = rebar3
ECHO = @echo
# Making the first target (BEAMs).
$(BEAM): $(SRCS)
$(REBAR3) compile
$(ECHO)
$(REBAR3) as prod compile
$(ECHO)
# Making the second target (releases).
$(SERV): $(BEAM)
$(REBAR3) release
$(ECHO)
$(ECHO)
$(REBAR3) as prod release
$(ECHO)
$(ECHO)
.PHONY: all clean
all: $(SERV)
clean:
$(REBAR3) clean
$(REBAR3) as prod clean
# vim:set nu ts=4 sw=4: