mirror of
https://github.com/correl/rebar.git
synced 2024-12-18 03:00:17 +00:00
Add new global flag 'debug_info' to erlc_compiler
Using rebar's commandline, enable/disable 'debug_info' for compilation. This feature if added to all rebar compilers could help simplify and standardize this common use case for all rebar build targets.
This commit is contained in:
parent
e36783112d
commit
d24021f4e3
1 changed files with 8 additions and 1 deletions
|
@ -99,7 +99,14 @@ doterl_compile(Config, OutDir) ->
|
|||
|
||||
doterl_compile(Config, OutDir, MoreSources) ->
|
||||
FirstErls = rebar_config:get_list(Config, erl_first_files, []),
|
||||
ErlOpts = filter_defines(rebar_config:get(Config, erl_opts, []), []),
|
||||
RawErlOpts = filter_defines(rebar_config:get(Config, erl_opts, []), []),
|
||||
ErlOpts =
|
||||
case rebar_config:get_global(debug_info, "0") of
|
||||
"0" ->
|
||||
RawErlOpts;
|
||||
_ ->
|
||||
[debug_info|RawErlOpts]
|
||||
end,
|
||||
?DEBUG("erl_opts ~p~n",[ErlOpts]),
|
||||
%% Support the src_dirs option allowing multiple directories to
|
||||
%% contain erlang source. This might be used, for example, should
|
||||
|
|
Loading…
Reference in a new issue