diff options
Diffstat (limited to 'gcc/java/jcf-dump.c')
-rw-r--r-- | gcc/java/jcf-dump.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/gcc/java/jcf-dump.c b/gcc/java/jcf-dump.c index 719105f..6a2714c 100644 --- a/gcc/java/jcf-dump.c +++ b/gcc/java/jcf-dump.c @@ -52,6 +52,7 @@ The Free Software Foundation is independent of Sun Microsystems, Inc. */ #include "system.h" #include "coretypes.h" #include "intl.h" +#include "diagnostic.h" #include "jcf.h" #include "tree.h" @@ -1172,12 +1173,22 @@ main (int argc, char** argv) { JCF jcf[1]; int argi, opt; + const char *p; + + p = argv[0] + strlen (argv[0]); + while (p != argv[0] && !IS_DIR_SEPARATOR (p[-1])) + --p; + progname = p; + + xmalloc_set_program_name (progname); /* Unlock the stdio streams. */ unlock_std_streams (); gcc_init_libintl (); + diagnostic_initialize (global_dc, 0); + if (argc <= 1) { fprintf (stderr, _("jcf-dump: no classes specified\n")); |