diff options
author | Siri Hansen <[email protected]> | 2012-03-20 15:51:54 +0100 |
---|---|---|
committer | Siri Hansen <[email protected]> | 2012-03-20 15:51:54 +0100 |
commit | f4a9831c176b3d477077a4e508e24777b2bf0342 (patch) | |
tree | 79c2dc2a9046f57273a6102c3173a15c5909c927 /lib/sasl | |
parent | 75c1050ae68d6914cf9be4f7e7267c0c4b12f157 (diff) | |
download | otp-f4a9831c176b3d477077a4e508e24777b2bf0342.tar.gz otp-f4a9831c176b3d477077a4e508e24777b2bf0342.tar.bz2 otp-f4a9831c176b3d477077a4e508e24777b2bf0342.zip |
Fix error message if stdlib has faulty start type in .rel file
If stdlib had a different start type than permanent, systools_make
would fail but it would say that it was sasl that had faulty start
type. This has been corrected.
Diffstat (limited to 'lib/sasl')
-rw-r--r-- | lib/sasl/src/systools_make.erl | 4 | ||||
-rw-r--r-- | lib/sasl/test/systools_SUITE.erl | 26 |
2 files changed, 26 insertions, 4 deletions
diff --git a/lib/sasl/src/systools_make.erl b/lib/sasl/src/systools_make.erl index 12ba2a5476..aca4ac0bba 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 @@ -482,7 +482,7 @@ mandatory_applications([_|Apps],Kernel,Stdlib,Sasl) -> mandatory_applications([],Type,_,_) when Type=/=permanent -> error_mandatory_application(kernel,Type); mandatory_applications([],_,Type,_) when Type=/=permanent -> - error_mandatory_application(sasl,Type); + error_mandatory_application(stdlib,Type); mandatory_applications([],_,_,undefined) -> {ok, [{warning,missing_sasl}]}; mandatory_applications([],_,_,_) -> diff --git a/lib/sasl/test/systools_SUITE.erl b/lib/sasl/test/systools_SUITE.erl index 4cf7364d74..c0e51d39e3 100644 --- a/lib/sasl/test/systools_SUITE.erl +++ b/lib/sasl/test/systools_SUITE.erl @@ -1,7 +1,7 @@ %% %% %CopyrightBegin% %% -%% Copyright Ericsson AB 2011. All Rights Reserved. +%% Copyright Ericsson AB 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 @@ -500,6 +500,22 @@ crazy_script(Config) when is_list(Config) -> {error, _, {mandatory_app,kernel,load}} = systools:make_script(LatestName3, [silent,{path,P}]), + %% Run with .rel file with non-permanent stdlib + {LatestDir4, LatestName4} = create_script(latest_stdlib_start_type, Config), + ok = file:set_cwd(LatestDir4), + + error = systools:make_script(LatestName4), + {error, _, {mandatory_app,stdlib,load}} = + systools:make_script(LatestName4, [silent,{path,P}]), + + %% Run with .rel file lacking stdlib + {LatestDir5, LatestName5} = create_script(latest_no_stdlib, Config), + ok = file:set_cwd(LatestDir5), + + error = systools:make_script(LatestName5), + {error, _, {missing_mandatory_app,stdlib}} = + systools:make_script(LatestName5, [silent,{path,P}]), + ok = file:set_cwd(OldDir), ok. @@ -2026,8 +2042,14 @@ create_script(latest_nokernel,Config) -> Apps = [{db,"2.1"},{fe,"3.1"}], do_create_script(latest_nokernel,Config,"4.4",Apps); create_script(latest_kernel_start_type,Config) -> - Apps = [{kernel,"1.0",load},{db,"2.1"},{fe,"3.1"}], + Apps = [{kernel,"1.0",load},{stdlib,"1.0"},{db,"2.1"},{fe,"3.1"}], do_create_script(latest_kernel_start_type,Config,"4.4",Apps); +create_script(latest_stdlib_start_type,Config) -> + Apps = [{kernel,"1.0"},{stdlib,"1.0",load},{db,"2.1"},{fe,"3.1"}], + do_create_script(latest_stdlib_start_type,Config,"4.4",Apps); +create_script(latest_no_stdlib,Config) -> + Apps = [{kernel,"1.0"},{db,"2.1"},{fe,"3.1"}], + do_create_script(latest_no_stdlib,Config,"4.4",Apps); create_script(latest_app_start_type1,Config) -> Apps = core_apps(current), do_create_script(latest_app_start_type1,Config,current,Apps); |