diff options
author | Tom Tromey <tromey@redhat.com> | 2001-08-16 21:52:14 +0000 |
---|---|---|
committer | Tom Tromey <tromey@gcc.gnu.org> | 2001-08-16 21:52:14 +0000 |
commit | 4266d0b2722db521925be85f61ca1fa643afe409 (patch) | |
tree | f06b613d253e0de5c16d60467024000787675cc3 /gcc/java/jcf-path.c | |
parent | 3c0a5af26c795b36e4f3a4bd56f787e8ea86d33e (diff) | |
download | gcc-4266d0b2722db521925be85f61ca1fa643afe409.zip gcc-4266d0b2722db521925be85f61ca1fa643afe409.tar.gz gcc-4266d0b2722db521925be85f61ca1fa643afe409.tar.bz2 |
jcf-dump.c (main): Updated for change to jcf_path_seal.
* jcf-dump.c (main): Updated for change to jcf_path_seal.
* gjavah.c (main): Updated for change to jcf_path_seal.
* lang.c (version_flag): New global.
(java_decode_option): Recognize `-version'.
(java_init): Update for change to jcf_path_seal.
* jcf.h (jcf_path_seal): Added `print' argument.
* jcf-path.c (jcf_path_seal): Added `print' argument.
From-SVN: r44946
Diffstat (limited to 'gcc/java/jcf-path.c')
-rw-r--r-- | gcc/java/jcf-path.c | 23 |
1 files changed, 20 insertions, 3 deletions
diff --git a/gcc/java/jcf-path.c b/gcc/java/jcf-path.c index a9e1bda..079cb36 100644 --- a/gcc/java/jcf-path.c +++ b/gcc/java/jcf-path.c @@ -1,6 +1,6 @@ /* Handle CLASSPATH, -classpath, and path searching. - Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc. + Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -311,9 +311,11 @@ jcf_path_include_arg (path) } /* We `seal' the path by linking everything into one big list. Then - we provide a way to iterate through the sealed list. */ + we provide a way to iterate through the sealed list. If PRINT is + true then we print the final class path to stderr. */ void -jcf_path_seal () +jcf_path_seal (print) + int print; { int do_system = 1; struct entry *secondary; @@ -351,6 +353,21 @@ jcf_path_seal () } else free_entry (&sys_dirs); + + if (print) + { + struct entry *ent; + fprintf (stderr, "Class path starts here:\n"); + for (ent = sealed; ent; ent = ent->next) + { + fprintf (stderr, " %s", ent->name); + if ((ent->flags & FLAG_SYSTEM)) + fprintf (stderr, " (system)"); + if ((ent->flags & FLAG_ZIP)) + fprintf (stderr, " (zip)"); + fprintf (stderr, "\n"); + } + } } void * |