This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
Patch: FYI: support -? and -X
- From: Tom Tromey <tromey at redhat dot com>
- To: GCC libjava patches <java-patches at gcc dot gnu dot org>
- Date: 12 Aug 2003 15:25:43 -0600
- Subject: Patch: FYI: support -? and -X
- Reply-to: tromey at redhat dot com
I'm checking this in on the trunk.
This patch adds support for -? and -X to gij. This was needed by
eclipse at one point. I'm not sure if it is still is, but it doesn't
hurt.
Tom
Index: libjava/ChangeLog
from Tom Tromey <tromey@redhat.com>
* gij.cc (main): Handle -? and -X.
Index: libjava/gij.cc
===================================================================
RCS file: /cvs/gcc/gcc/libjava/gij.cc,v
retrieving revision 1.20
diff -u -r1.20 gij.cc
--- libjava/gij.cc 25 Oct 2002 03:28:00 -0000 1.20
+++ libjava/gij.cc 6 Feb 2003 19:04:40 -0000
@@ -1,4 +1,4 @@
-/* Copyright (C) 1999, 2000, 2001, 2002 Free Software Foundation
+/* Copyright (C) 1999, 2000, 2001, 2002, 2003 Free Software Foundation
This file is part of libgcj.
@@ -90,7 +90,7 @@
if (arg[1] == '-')
++arg;
- if (! strcmp (arg, "-help"))
+ if (! strcmp (arg, "-help") || ! strcmp (arg, "-?"))
help ();
else if (! strcmp (arg, "-version"))
{
@@ -131,6 +131,15 @@
// then the jar code will override this. This is the
// correct behavior.
_Jv_Jar_Class_Path = argv[++i];
+ }
+ else if (arg[1] == 'X')
+ {
+ if (arg[2] == '\0')
+ {
+ printf ("gij: currently no -X options are recognized\n");
+ exit (0);
+ }
+ /* Ignore other -X options. */
}
else
{