|
|
@ -72,11 +72,12 @@ validate_application_info(AppInfo, AppDetail) -> |
|
|
|
undefined -> |
|
|
|
false; |
|
|
|
AppFile -> |
|
|
|
case get_modules_list(AppFile, AppDetail) of |
|
|
|
{ok, List} -> |
|
|
|
has_all_beams(EbinDir, List); |
|
|
|
_Error -> |
|
|
|
?PRV_ERROR({module_list, AppFile}) |
|
|
|
case proplists:get_value(modules, AppDetail) of |
|
|
|
undefined -> |
|
|
|
?PRV_ERROR({module_list, AppFile}); |
|
|
|
List -> |
|
|
|
has_all_beams(EbinDir, List) |
|
|
|
|
|
|
|
end |
|
|
|
end. |
|
|
|
|
|
|
@ -84,18 +85,6 @@ validate_application_info(AppInfo, AppDetail) -> |
|
|
|
%% Internal functions |
|
|
|
%% =================================================================== |
|
|
|
|
|
|
|
-spec get_modules_list(file:filename_all(), proplists:proplist()) -> |
|
|
|
{ok, list()} | |
|
|
|
{warning, Reason::term()} | |
|
|
|
{error, Reason::term()}. |
|
|
|
get_modules_list(AppFile, AppDetail) -> |
|
|
|
case proplists:get_value(modules, AppDetail) of |
|
|
|
undefined -> |
|
|
|
{warning, {invalid_app_file, AppFile}}; |
|
|
|
ModulesList -> |
|
|
|
{ok, ModulesList} |
|
|
|
end. |
|
|
|
|
|
|
|
-spec has_all_beams(file:filename_all(), list()) -> true | providers:error(). |
|
|
|
has_all_beams(EbinDir, [Module | ModuleList]) -> |
|
|
|
BeamFile = filename:join([EbinDir, |
|
|
|