diff options
Diffstat (limited to 'tools')
-rw-r--r-- | tools/gnu/classpath/tools/getopt/OptionGroup.java | 13 | ||||
-rw-r--r-- | tools/gnu/classpath/tools/getopt/Parser.java | 1 |
2 files changed, 11 insertions, 3 deletions
diff --git a/tools/gnu/classpath/tools/getopt/OptionGroup.java b/tools/gnu/classpath/tools/getopt/OptionGroup.java index 35e812b2d..518d9f938 100644 --- a/tools/gnu/classpath/tools/getopt/OptionGroup.java +++ b/tools/gnu/classpath/tools/getopt/OptionGroup.java @@ -147,9 +147,16 @@ public class OptionGroup { if (argName != null) { - out.print(' '); + // This is a silly hack just for '-J'. We don't + // support joined options in general, but this option + // is filtered out before argument processing can see it. + if (option.getShortName() != 'J') + { + out.print(' '); + ++column; + } out.print(argName); - column += 1 + argName.length(); + column += argName.length(); } out.print(" "); } @@ -168,7 +175,7 @@ public class OptionGroup column += (longOnly ? 1 : 2) + option.getLongName().length(); if (argName != null) { - out.print("=" + argName); + out.print(" " + argName); column += 1 + argName.length(); } } diff --git a/tools/gnu/classpath/tools/getopt/Parser.java b/tools/gnu/classpath/tools/getopt/Parser.java index 6e5e61b94..e6fdb1037 100644 --- a/tools/gnu/classpath/tools/getopt/Parser.java +++ b/tools/gnu/classpath/tools/getopt/Parser.java @@ -120,6 +120,7 @@ public class Parser { // -J should be handled by the appletviewer wrapper binary. // We add it here so that it shows up in the --help output. + // Note that there is a special case for this in OptionGroup. } }); add(finalGroup); |