//\r
// Add more logic process here\r
//\r
- throw new BuildException(e.getMessage());\r
+ BuildException buildException = new BuildException(e.getMessage());\r
+ buildException.setStackTrace(e.getStackTrace());\r
+ throw buildException;\r
} catch (PcdAutogenException e) {\r
//\r
// Add more logic process here\r
//\r
- throw new BuildException(e.getMessage());\r
+ BuildException buildException = new BuildException(e.getMessage());\r
+ buildException.setStackTrace(e.getStackTrace());\r
+ throw buildException;\r
} catch (AutoGenException e) {\r
//\r
// Add more logic process here\r
//\r
- throw new BuildException(e.getMessage());\r
+ BuildException buildException = new BuildException(e.getMessage());\r
+ buildException.setStackTrace(e.getStackTrace());\r
+ throw buildException;\r
} catch (PlatformPcdPreprocessBuildException e) {\r
//\r
// Add more logic process here\r
//\r
- throw new BuildException(e.getMessage());\r
+ BuildException buildException = new BuildException(e.getMessage());\r
+ buildException.setStackTrace(e.getStackTrace());\r
+ throw buildException;\r
} catch (GenBuildException e) {\r
//\r
// Add more logic process here\r
//\r
- throw new BuildException(e.getMessage());\r
+ BuildException buildException = new BuildException(e.getMessage());\r
+ buildException.setStackTrace(e.getStackTrace());\r
+ throw buildException;\r
} catch (EdkException e) {\r
//\r
// Add more logic process here\r
//\r
- throw new BuildException(e.getMessage());\r
+ BuildException buildException = new BuildException(e.getMessage());\r
+ buildException.setStackTrace(e.getStackTrace());\r
+ throw buildException;\r
}\r
}\r
\r
// First, add the library instance without consumers to the Q\r
//\r
for (int i = 0; i < libInstanceList.length; ++i) {\r
- if (libInstanceConsumedBy.get(libInstanceList[i]).size() == 0) {\r
+ if (libInstanceList[i] == null) {\r
+ continue;\r
+ }\r
+ \r
+ if (libInstanceConsumedBy.get(libInstanceList[i]) == null || libInstanceConsumedBy.get(libInstanceList[i]).size() == 0) {\r
noConsumerList.add(libInstanceList[i]);\r
}\r
}\r
continue;\r
}\r
HashSet<ModuleIdentification> consumedBy = libInstanceConsumedBy.get(m);\r
- if (consumedBy.size() == 0) {\r
+ if (consumedBy == null || consumedBy.size() == 0) {\r
continue;\r
}\r
\r
}\r
\r
HashSet<ModuleIdentification> consumedBy = libInstanceConsumedBy.get(libInstance);\r
- if (consumedBy.size() == 0) {\r
+ if (consumedBy == null || consumedBy.size() == 0) {\r
continue;\r
}\r
\r
boolean HasError = false;\r
for (int i = 0; i < libInstanceList.length; ++i) {\r
HashSet<ModuleIdentification> consumedBy = libInstanceConsumedBy.get(libInstanceList[i]);\r
- if (consumedBy.size() > 0 && libInstanceList[i].hasConstructor()) {\r
+ if (consumedBy != null && consumedBy.size() > 0 && libInstanceList[i].hasConstructor()) {\r
EdkLog.log(EdkLog.EDK_ERROR, libInstanceList[i].getName()\r
+ " with constructor has a circular dependency!");\r
ModuleIdentification[] consumedByList = consumedBy.toArray(new ModuleIdentification[consumedBy.size()]);\r