aboutsummaryrefslogtreecommitdiffstats
path: root/lib/reltool/src/reltool_target.erl
diff options
context:
space:
mode:
Diffstat (limited to 'lib/reltool/src/reltool_target.erl')
-rw-r--r--lib/reltool/src/reltool_target.erl24
1 files changed, 15 insertions, 9 deletions
diff --git a/lib/reltool/src/reltool_target.erl b/lib/reltool/src/reltool_target.erl
index 3d83a77d99..e3a7b02143 100644
--- a/lib/reltool/src/reltool_target.erl
+++ b/lib/reltool/src/reltool_target.erl
@@ -155,6 +155,7 @@ do_gen_config(#app{name = Name,
archive_opts = ArchiveOpts,
use_selected_vsn = UseSelected,
vsn = Vsn,
+ active_dir = ActiveDir,
mods = Mods,
is_included = IsIncl},
InclDefs) ->
@@ -170,9 +171,10 @@ do_gen_config(#app{name = Name,
emit(excl_archive_filters, ExclArchiveDirs, undefined, InclDefs),
emit(archive_opts, ArchiveOpts, undefined, InclDefs),
if
- IsIncl, InclDefs -> [{vsn, Vsn}];
- UseSelected -> [{vsn, Vsn}];
- true -> []
+ IsIncl, InclDefs -> [{vsn, Vsn}, {lib_dir, ActiveDir}];
+ UseSelected =:= vsn -> [{vsn, Vsn}];
+ UseSelected =:= dir -> [{lib_dir, ActiveDir}];
+ true -> []
end,
[do_gen_config(M, InclDefs) || M <- Mods]
],
@@ -247,10 +249,15 @@ gen_app(#app{name = Name,
env = Env,
mod = StartMod,
start_phases = StartPhases}}) ->
- StartMod2 =
- case StartMod =:= undefined of
- true -> [];
- false -> [{mod, StartMod}]
+ StartPhases2 =
+ case StartPhases of
+ undefined -> [];
+ _ -> [{start_phases, StartPhases}]
+ end,
+ Tail =
+ case StartMod of
+ undefined -> StartPhases2;
+ _ -> [{mod, StartMod} | StartPhases2]
end,
{application, Name,
[{description, Desc},
@@ -261,10 +268,9 @@ gen_app(#app{name = Name,
{applications, ReqApps},
{included_applications, InclApps},
{env, Env},
- {start_phases, StartPhases},
{maxT, MaxT},
{maxP, MaxP} |
- StartMod2]}.
+ Tail]}.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Generate the contents of a rel file