-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrebar.config
130 lines (93 loc) · 6.28 KB
/
rebar.config
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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
% This is a configuration file of rebar3, so that the US-Common application can
% better integrate in the current OTP ecosystem, despite its (more complex,
% probably more flexible) native build based on GNU make.
%
% If the name of this file is 'rebar.config', then it is a generated file,
% otherwise it is a template (located in conf/rebar.config.template), meant to
% be filled by information determined at build time or coming from
% GNUmakevars.inc.
%
% See the Myriad counterpart file (same name) for more explanations.
% Base layout was obtained thanks to: 'rebar3 new app us_common', as US-Common
% is an active OTP application (not a mere library).
% To be taken into account, from the library root, through 'make
% rebar3-application' or 'make rebar3-release'.
% Settings for the 'default' profile follow.
% Depends on the following applications (Erlang implied):
{deps, [
{myriad, {git, "https://github.com/Olivier-Boudeville/Ceylan-Myriad.git",
{branch, "master"}}},
{wooper, {git, "https://github.com/Olivier-Boudeville/Ceylan-WOOPER.git",
{branch, "master"}}},
{traces, {git, "https://github.com/Olivier-Boudeville/Ceylan-Traces.git",
{branch, "master"}}}
]}.
% Include directories found in INC:
{erl_opts, [ {us_common_version,"0.1.5"}, {d,myriad_debug_mode}, {d,wooper_debug_mode}, {d,traces_debug_mode}, {d,us_common_debug_mode}, {d,tracing_activated}, debug_info, {debug_info_key,"Ceylan-Myriad"}, report_warnings, warn_export_all, warn_export_vars, warn_shadow_vars, warn_obsolete_guards, warn_unused_import, warnings_as_errors, {parse_transform,wooper_parse_transform}, {i,"../traces/../wooper/src/interfaces"}, {i,"include"}, {i,".."}, {i,"../traces/include"}, {i,"../traces/.."}, {i,"../traces/../wooper/include"}, {i,"../traces/../wooper/include/interfaces"}, {i,"../traces/../wooper/.."}, {i,"../traces/../wooper/../myriad/include/apps/generate-password"}, {i,"../traces/../wooper/../myriad/include/apps/merge-tool"}, {i,"../traces/../wooper/../myriad/include/data-management"}, {i,"../traces/../wooper/../myriad/include/maths"}, {i,"../traces/../wooper/../myriad/include/meta"}, {i,"../traces/../wooper/../myriad/include/scripts"}, {i,"../traces/../wooper/../myriad/include/user-interface/graphical"}, {i,"../traces/../wooper/../myriad/include/user-interface/textual"}, {i,"../traces/../wooper/../myriad/include/user-interface/audio"}, {i,"../traces/../wooper/../myriad/include/user-interface"}, {i,"../traces/../wooper/../myriad/include/utils"}, {i,"../traces/../wooper/../myriad/.."}, {i,"../traces/../wooper/../myriad/ebin"} ]}.
% (hooks needed, for example to create the include symlinks and for the build
% itself)
%
% Previously 'MYRIAD_REBAR_PROFILE=${REBAR_PROFILE}' was added, yet
% REBAR_PROFILE is actually not set, so we rely on our default value instead.
%
% Hooks had to be even strengthened, otherwise spurious, ill-configured
% compilations will be wrongly attempted by rebar3, when used as a dependency:
%
%{pre_hooks, [ {compile, "make -s rebar3-compile-pre-hook"} ]}.
%{post_hooks, [ {compile, "make -s rebar3-compile-post-hook"} ]}.
% Used now for homogeneity:
{pre_hooks, [ {compile, "make -s rebar3-bulletproof-compile-pre-hook"} ]}.
{post_hooks, [ {compile, "make -s rebar3-bulletproof-compile-post-hook"} ]}.
% For release generation:
%
% (defaults are for the development mode)
%
% With relx, only direct dependencies need to be listed, and version constraints
% can be used, instead of exact, specific versions.
%
{relx, [
% Not 'us_common_release', otherwise plenty of paths will be cluttered:
{release, {us_common, "0.1.5"},
% Listing an application here seems necessary (otherwise its .app file will
% not be found), however it will also result in its automatic starting with
% no specfied arguments, whereas at least for some (e.g. simple_bridge) we
% need to specify them (e.g. which backend to be used).
%
% Listing 'traces' here implies its prerequisites (namely Myriad and WOOPER)
% and is needed, otherwise their respective modules will not be in the
% code path:
%
[ traces, us_common ] },
{sys_config, "conf/sys.config"},
% We need specified VM arguments (notably: long node names wanted):
{vm_args, "conf/vm.args"},
{dev_mode, true},
{include_erts, false},
{extended_start_script, true},
{include_src, false}
] }.
{profiles, [
% Production mode (the default one when used as a dependency):
{prod, [
% Like for the default profile, except for removed {d,myriad_debug_mode},
% {d,wooper_debug_mode}, {d,traces_debug_mode}, {d,us_common_debug_mode} and
% {d,tracing_activated}, and added {d,exec_target_is_production}:
%
{erl_opts, [ {us_common_version,"0.1.5"}, {d,exec_target_is_production}, debug_info, {debug_info_key,"Ceylan-Myriad"}, report_warnings, warn_export_all, warn_export_vars, warn_shadow_vars, warn_obsolete_guards, warn_unused_import, warnings_as_errors, {parse_transform,wooper_parse_transform}, {i,"../traces/../wooper/src/interfaces"}, {i,"include"}, {i,".."}, {i,"../traces/include"}, {i,"../traces/.."}, {i,"../traces/../wooper/include"}, {i,"../traces/../wooper/include/interfaces"}, {i,"../traces/../wooper/.."}, {i,"../traces/../wooper/../myriad/include/apps/generate-password"}, {i,"../traces/../wooper/../myriad/include/apps/merge-tool"}, {i,"../traces/../wooper/../myriad/include/data-management"}, {i,"../traces/../wooper/../myriad/include/maths"}, {i,"../traces/../wooper/../myriad/include/meta"}, {i,"../traces/../wooper/../myriad/include/scripts"}, {i,"../traces/../wooper/../myriad/include/user-interface/graphical"}, {i,"../traces/../wooper/../myriad/include/user-interface/textual"}, {i,"../traces/../wooper/../myriad/include/user-interface/audio"}, {i,"../traces/../wooper/../myriad/include/user-interface"}, {i,"../traces/../wooper/../myriad/include/utils"}, {i,"../traces/../wooper/../myriad/.."}, {i,"../traces/../wooper/../myriad/ebin"} ]},
% For the build makefiles:
{env, [ { 'REBAR_PROFILE', "prod" } ] },
{relx, [
% Not wanting the release to contain symlinks to applications:
{dev_mode, false},
% Creating a full target system:
%{include_erts, true},
% Or sharing a local Erlang environment (then the OTP versions must
% precisely match):
%
{include_erts, false},
{extended_start_script, true},
{include_src, false}
]} ] }
% No test profile currently needed.
]}.
% No Hex package wanted with this version.