anchor.diff:                               fun() ->
                                        rlx_release:format(0, Release1)
                                end),
  -            {ok, rlx_state:add_realized_release(State, Release1)};
  +            case rlx_state:get(State, include_erts, undefined) of
  +                IncludeErts when is_atom(IncludeErts) ->
  +                    {ok, rlx_state:add_realized_release(State, Release1)};
  +                ErtsDir ->
  +                    try
  +                        [Erts | _] = filelib:wildcard(filename:join(ErtsDir, "erts-*")),
  +                        [_, ErtsVsn] = string:tokens(filename:basename(Erts), "-"),
  +                        {ok, rlx_state:add_realized_release(State, rlx_release:erts(Release1, ErtsVsn))}
  +                    catch
  +                        _:_ ->
  +                            ?RLX_ERROR({release_erts_error, ErtsDir})
  +                    end
  +            end;
           {error, E} ->
               ?RLX_ERROR({release_error, E})
       end.
  
positive.code:     io_lib:format("No releases exist in the system for ~p:~s!", [RelName, RelVsn]);
  format_error({failed_solve, Error}) ->
      io_lib:format("Failed to solve release:\n ~s",
                    [rlx_depsolver:format_error({error, Error})]).
  
  %%%===================================================================
  %%% Internal Functions
  
negative.code:     end.
  
  set_resolved(State, Release0, Pkgs) ->
      case rlx_release:realize(Release0, Pkgs, rlx_state:available_apps(State)) of
          {ok, Release1} ->
              ec_cmd_log:info(rlx_state:log(State),
  