This does not get rid of all warnings.
This fixes the HiPE dependency to be conditional to whether dialyzer
actually requires it or not, and makes use of the .app.src.script
feature internally, at build time. This may cause issues for scripts
built prior to OTP-24 being used for OTP-24 versions as it will ask for
apps that aren't in place, but there's no good work-around for that.
This also bumps the erlware-commons version to one that eliminates some
warnings, and makes the bootstrap script honor the warnings_as_errors
value of dependencies to allow the build to proceed until parse_trans is
fixed upstream.
This patch fixes incorrect behaviour of rebar_compiler_epp that
finds dependencies in _build/test/lib/... folder when rebar3 is run with
test profile. It is caused by code:lib_dir() pointing to _build
directory (when ebin is added to code path). Problem originates in
OTP that expects "include" and "ebin" directories being next to each other,
but rebar3 separates build artifacts and include files.
This patch also significantly speeds up analisys, caching file-to-application
mapping and avoiding repeated lookup for the very same gen_server/...
1. we now rely on $1's vendor.sh script (instead of duplicating it here)
2. we assume that hex_core is rebar3-compatible
3. we rely on TARGET_ERLANG_VERSION
4. we generate exactly what was previously generating, while targeting a specific Erlang/OTP vsn
The shell plugin has to reset the logger by fetching its configuration and
re-applying it later. In the current state, `maybe_reset_logger/1` will only
re-apply part of the configuration (the `config` key), which does not include
other settings such as filters and formatters.
The effect can be demonstrated by adding filters or formatters to `~/.erlang`
and running rebar3 shell on any project (without any --config argument, this
one reload the logger env; updating the kernel/logger environment in
`~/.erlang` fixes it).
For example:
```erlang
logger:set_handler_config(default, #{formatter => {logger_formatter,
#{template => ["> ", msg, "\n"]}}}).
```
This patch makes sure the default handler is re-created with its entire
original configuration.
relx:build_relup does not allow for undefined Release or ToVsn
so we verify that they have been given on the command line
before running relx:build_relup/4.
Based on the closest Alpine Erlang version currently supported by
rebar3. Allows people to mix and match different versions of
the Erlang VM and rebar3 using multi-stage builds.