summaryrefslogtreecommitdiff
path: root/bootstrap
diff options
context:
space:
mode:
Diffstat (limited to 'bootstrap')
-rwxr-xr-xbootstrap10
1 files changed, 7 insertions, 3 deletions
diff --git a/bootstrap b/bootstrap
index e2a393b..323b0a5 100755
--- a/bootstrap
+++ b/bootstrap
@@ -24,7 +24,7 @@ main(_) ->
bootstrap_rebar3(),
%% Build rebar.app from rebar.app.src
- {ok, App} = rebar_app_info:new(rebar, "3.1.0", filename:absname("_build/default/lib/rebar/")),
+ {ok, App} = rebar_app_info:new(rebar, "3.1.1", filename:absname("_build/default/lib/rebar/")),
rebar_otp_app:compile(rebar_state:new(), App),
%% Because we are compiling files that are loaded already we want to silence
@@ -133,7 +133,11 @@ get_rebar_config() ->
end.
get_http_vars(Scheme) ->
- proplists:get_value(Scheme, get_rebar_config(), []).
+ OS = case os:getenv(atom_to_list(Scheme)) of
+ Str when is_list(Str) -> Str;
+ _ -> []
+ end,
+ proplists:get_value(Scheme, get_rebar_config(), OS).
set_httpc_options() ->
set_httpc_options(https_proxy, get_http_vars(https_proxy)),
@@ -350,7 +354,7 @@ format_error(AbsSource, Extra, {Mod, Desc}) ->
io_lib:format("~s: ~s~s~n", [AbsSource, Extra, ErrorDesc]).
additional_defines() ->
- [{d, D} || {Re, D} <- [{"^[0-9]+", namespaced_types}, {"^R1[4|5]", deprecated_crypto}], is_otp_release(Re)].
+ [{d, D} || {Re, D} <- [{"^[0-9]+", namespaced_types}, {"^R1[4|5]", deprecated_crypto}, {"^((1[8|9])|2)", rand_module}], is_otp_release(Re)].
is_otp_release(ArchRegex) ->
case re:run(otp_release(), ArchRegex, [{capture, none}]) of