summaryrefslogtreecommitdiff
path: root/Tools
diff options
context:
space:
mode:
authorjwang36 <jwang36@6f19259b-4bc3-4df7-8a09-765794883524>2007-02-05 02:02:15 +0000
committerjwang36 <jwang36@6f19259b-4bc3-4df7-8a09-765794883524>2007-02-05 02:02:15 +0000
commit2f96bdd1b9358bb1b14e6c6c7399756dbbb9f222 (patch)
treec02233919a4e0deb8095c17e19585378eea74468 /Tools
parente64872fa8b577189395edb6624b9e178989fd3e5 (diff)
Output more descriptive information when there's no TARGET, TARGET_ARCH, etc defined in target.txt
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@2351 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'Tools')
-rw-r--r--Tools/Java/Source/ContextTool/org/tianocore/context/ParseParameter.java36
1 files changed, 30 insertions, 6 deletions
diff --git a/Tools/Java/Source/ContextTool/org/tianocore/context/ParseParameter.java b/Tools/Java/Source/ContextTool/org/tianocore/context/ParseParameter.java
index 24adfb70f..4d9c6de3a 100644
--- a/Tools/Java/Source/ContextTool/org/tianocore/context/ParseParameter.java
+++ b/Tools/Java/Source/ContextTool/org/tianocore/context/ParseParameter.java
@@ -78,7 +78,11 @@ public class ParseParameter {
// argstr is "-p ", display current setting
//
if(argstr.length() < 4 && argstr.charAt(2) == ' '){
- System.out.printf("%s\n", curpstr);
+ if (curpstr != null) {
+ System.out.printf("%s\n", curpstr);
+ } else {
+ System.out.printf("No ACTIVE_PLATFORM defined \n");
+ }
return 1;
}
//
@@ -106,7 +110,11 @@ public class ParseParameter {
npflag = true;
} else if (argstr.charAt(1) == 't') {
if(argstr.length() < 4 && argstr.charAt(2) == ' '){
- System.out.printf("%s\n", curtstr);
+ if (curtstr != null) {
+ System.out.printf("%s\n", curtstr);
+ } else {
+ System.out.printf("No TARGET defined\n");
+ }
return 1;
}
if(argstr.length() < 6 && argstr.charAt(3) == '?'){
@@ -122,7 +130,11 @@ public class ParseParameter {
ntflag = true;
} else if (argstr.charAt(1) == 'a') {
if(argstr.length() < 4 && argstr.charAt(2) == ' '){
- System.out.printf("%s\n", curastr);
+ if (curastr != null) {
+ System.out.printf("%s\n", curastr);
+ } else {
+ System.out.printf("No TARGET_ARCH defined\n");
+ }
return 1;
}
if(argstr.length() < 6 && argstr.charAt(3) == '?'){
@@ -138,7 +150,11 @@ public class ParseParameter {
naflag = true;
} else if (argstr.charAt(1) == 'c') {
if(argstr.length() < 4 && argstr.charAt(2) == ' '){
- System.out.printf("%s\n", curcstr);
+ if (curcstr != null) {
+ System.out.printf("%s\n", curcstr);
+ } else {
+ System.out.printf("No TOOL_CHAIN_CONF defined\n");
+ }
return 1;
}
if(argstr.length() < 6 && argstr.charAt(3) == '?'){
@@ -160,7 +176,11 @@ public class ParseParameter {
ncflag = true;
} else if (argstr.charAt(1) == 'n') {
if(argstr.length() < 4 && argstr.charAt(2) == ' '){
- System.out.printf("%s\n", curnstr);
+ if (curnstr != null) {
+ System.out.printf("%s\n", curnstr);
+ } else {
+ System.out.printf("No TOOL_CHAIN_TAG defined\n");
+ }
return 1;
}
if(argstr.length() < 6 && argstr.charAt(3) == '?'){
@@ -176,7 +196,11 @@ public class ParseParameter {
nnflag = true;
} else if (argstr.charAt(1) == 'm') {
if(argstr.length() < 4 && argstr.charAt(2) == ' '){
- System.out.printf("%s\n", curmstr);
+ if (curmstr != null) {
+ System.out.printf("%s\n", curmstr);
+ } else {
+ System.out.printf("No MAX_CONCURRENT_THREAD_NUMBER defined\n");
+ }
return 1;
}
if(argstr.length() < 6 && argstr.charAt(3) == '?'){