This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
Re: Patch: FYI: support -? and -X
- From: Tom Tromey <tromey at redhat dot com>
- To: Ranjit Mathew <rmathew at hotmail dot com>
- Cc: java-patches at gcc dot gnu dot org
- Date: 13 Aug 2003 07:27:11 -0600
- Subject: Re: Patch: FYI: support -? and -X
- References: <87vft2va94.fsf@fleche.redhat.com> <bhcfb8$gq4$1@sea.gmane.org>
- Reply-to: tromey at redhat dot com
>>>>> "Ranjit" == Ranjit Mathew <rmathew@hotmail.com> writes:
>> + printf ("gij: currently no -X options are recognized\n");
Ranjit> printf ("%s: currently no -X options are recognized\n", argv[0]);
Ranjit> Or not?
I was following the convention already in the code.
I'm not certain this is best.
It's usually pretty ugly when the program prints:
/foo/bar/install/bin/gij: blah blah blah
OTOH, it is confusing if you have a symlink named "java" or something
and it prints "gij". I think some people compromise by stripping off
the directory components from argv[0].
The standards seem pretty silent on this. AFAICT they only talk
about the specific case of what to print for --version.
>> + exit (0);
Ranjit> exit (1);
Ranjit> Since this is an error and the execution did not succeed.
`gij -X' is a request to print the supported -X options. So, it did
succeed.
BTW I consider this patch a bit of a hack. We probably could
meaningfully support some -X options; at least -Xmx and -Xms, and
maybe some GC debugging options.
Tom