aboutsummaryrefslogtreecommitdiffstats
path: root/lib/sasl/src/systools_make.erl
diff options
context:
space:
mode:
authorSiri Hansen <[email protected]>2012-03-20 14:38:50 +0100
committerSiri Hansen <[email protected]>2012-03-20 14:45:29 +0100
commit5e575f65629f6d99ed423bc646219c162f6bfa1a (patch)
tree55d112760d20070d2a8fcc2f59a03c5007ba8697 /lib/sasl/src/systools_make.erl
parent700e7ee884e3ae19a43a05e8a24f90ab703e6890 (diff)
downloadotp-5e575f65629f6d99ed423bc646219c162f6bfa1a.tar.gz
otp-5e575f65629f6d99ed423bc646219c162f6bfa1a.tar.bz2
otp-5e575f65629f6d99ed423bc646219c162f6bfa1a.zip
Avoid undefined start_phases entry in .script
Inorder to align with reltool a {start_phases,undefined} entry in will no longer occur in the application specification in .script files. The start_phases entry will only exist if it contains real start phases. Also, the default value for #application.start_phases is no longer set to [] in systools.hrl. This value was actually never used, since it was always explicitly set in systools_make:parse_applications - by default to 'undefined', so the default value in the record definition was only a confusing detail. Anyway - now corrected.
Diffstat (limited to 'lib/sasl/src/systools_make.erl')
-rw-r--r--lib/sasl/src/systools_make.erl17
1 files changed, 10 insertions, 7 deletions
diff --git a/lib/sasl/src/systools_make.erl b/lib/sasl/src/systools_make.erl
index 12ba2a5476..a2ea9a8d7e 100644
--- a/lib/sasl/src/systools_make.erl
+++ b/lib/sasl/src/systools_make.erl
@@ -1,7 +1,7 @@
%%
%% %CopyrightBegin%
%%
-%% Copyright Ericsson AB 1996-2011. All Rights Reserved.
+%% Copyright Ericsson AB 1996-2012. All Rights Reserved.
%%
%% The contents of this file are subject to the Erlang Public License,
%% Version 1.1, (the "License"); you may not use this file except in
@@ -1456,15 +1456,18 @@ pack_app(#application{name=Name,vsn=V,id=Id,description=D,modules=M,
{applications, App},
{included_applications, Incs},
{env, Env},
- {start_phases, SF},
{maxT, MaxT},
{maxP, MaxP} |
- behave(Mod)]}.
-
+ behave([{start_phases,SF},{mod,Mod}])]}.
+
+behave([{mod,[]}|T]) ->
+ behave(T);
+behave([{start_phases,undefined}|T]) ->
+ behave(T);
+behave([H|T]) ->
+ [H|behave(T)];
behave([]) ->
- [];
-behave(Mod) ->
- [{mod, Mod}].
+ [].
%%______________________________________________________________________
%% mandatory modules; this modules must be loaded before processes