From f6390d375c84a8dd7adbc2c76381b6bd41e256d8 Mon Sep 17 00:00:00 2001 From: wuyizhong Date: Tue, 26 Sep 2006 03:10:34 +0000 Subject: [PATCH] Add one more judgement for modulelist specified but empty. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@1624 6f19259b-4bc3-4df7-8a09-765794883524 --- .../GenBuild/org/tianocore/build/fpd/FpdParserTask.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Tools/Source/GenBuild/org/tianocore/build/fpd/FpdParserTask.java b/Tools/Source/GenBuild/org/tianocore/build/fpd/FpdParserTask.java index 106e6d6a07..b496e32ed5 100644 --- a/Tools/Source/GenBuild/org/tianocore/build/fpd/FpdParserTask.java +++ b/Tools/Source/GenBuild/org/tianocore/build/fpd/FpdParserTask.java @@ -283,17 +283,20 @@ public class FpdParserTask extends Task { Set filesSet = fvs.get(validFv[i]); FpdModuleIdentification[] files = null; + if (moduleSeqSet == null) { if (filesSet != null) { files = filesSet.toArray(new FpdModuleIdentification[filesSet.size()]); } + } else if (filesSet == null) { + if (moduleSeqSet.size() != 0) { + throw new BuildException("Can not find any modules belongs to FV[" + validFv[i] + "], but listed some in BuildOptions.UserExtensions[@UserID='IMAGES' @Identifier='1']"); + } } else { // // if moduleSeqSet and filesSet is inconsistent, report error // - if (filesSet == null && moduleSeqSet.size() != 0) { - throw new BuildException("Can not find any modules belongs to FV[" + validFv[i] + "], but listed some in BuildOptions.UserExtensions[@UserID='IMAGES' @Identifier='1']"); - } else if(moduleSeqSet.size() != filesSet.size()){ + if(moduleSeqSet.size() != filesSet.size()){ throw new BuildException("Modules for FV[" + validFv[i] + "] defined in FrameworkModules and in BuildOptions.UserExtensions[@UserID='IMAGES' @Identifier='1'] are inconsistent. "); } else { //