idegen fails to build a correct dependency graph if one of the submodules it identifies lacks an Android.mk file
The current failure mode is for the tool to throw an Exception and stop. This commit makes it possible for the tool to continue in the face of such a missing .mk file. Test: manual Change-Id: I42991fe7cda07e0fae2eb037649d88133afde1c7
This commit is contained in:
@@ -71,12 +71,19 @@ public class ModuleCache {
|
||||
Preconditions.checkState(indexes != null, "You must call init() first.");
|
||||
Preconditions.checkNotNull(moduleName);
|
||||
|
||||
String makeFile = indexes.getMakeFile(moduleName);
|
||||
if (makeFile == null) {
|
||||
String makeFileName = indexes.getMakeFile(moduleName);
|
||||
if (makeFileName == null) {
|
||||
logger.warning("Unable to find make file for module: " + moduleName);
|
||||
return null;
|
||||
}
|
||||
return getAndCacheByDir(new File(makeFile).getParentFile());
|
||||
|
||||
File makeFile = new File(makeFileName);
|
||||
if (!makeFile.exists()) {
|
||||
logger.warning("Unable to find make file for module: " + moduleName);
|
||||
return null;
|
||||
}
|
||||
|
||||
return getAndCacheByDir(makeFile.getParentFile());
|
||||
}
|
||||
|
||||
private void putModule(File moduleDir, Module module) throws IOException {
|
||||
|
||||
Reference in New Issue
Block a user