This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
[ecj] Patch: FYI: remove temp files
- From: Tom Tromey <tromey at redhat dot com>
- To: Java Patch List <java-patches at gcc dot gnu dot org>
- Cc: Gcc Patch List <gcc-patches at gcc dot gnu dot org>
- Date: 12 Jul 2006 13:56:35 -0600
- Subject: [ecj] Patch: FYI: remove temp files
- Reply-to: tromey at redhat dot com
I'm checking this in on the gcj-eclipse branch.
This fixes PR 28329. We weren't properly unlinking temporary files.
The problem was that GCC's temporary file code assumes '%U' is used as
an argument by itself. The fix is to make this always be the case; I
introduced a new 'internal only' option to make this simpler.
Tom
Index: ChangeLog
from Tom Tromey <tromey@redhat.com>
PR java/28329:
* lang-specs.h: Pass '%U'-based options as separate arguments.
Use -faux-classpath.
* lang.c (java_handle_option): Handle OPT_faux_classpath.
* lang.opt (faux-classpath): New option.
Index: lang-specs.h
===================================================================
--- lang-specs.h (revision 115306)
+++ lang-specs.h (working copy)
@@ -44,12 +44,12 @@
%{foutput-class-dir*} %{g*} \
%{fsource*} %{!fsource*:-fsource=1.5} \
%{ftarget*} %{!femit-class-files|!ftarget*:-ftarget=1.5} \
- %{!findirect-dispatch:-fzip-dependency=%U.zip} \
- %{!fsyntax-only:-fzip-target=%U.jar}}\n \
+ %{!findirect-dispatch:-fzip-dependency %U.zip} \
+ %{!fsyntax-only:-fzip-target %U.jar}}\n \
%{.class|.zip|.jar|!fsyntax-only:jc1 \
%{.java|fsaw-java-file:%U.jar -fsource-filename=%i %<ffilelist-file} \
%{.class|.zip|.jar|ffilelist-file|fcompile-resource*:%i} \
- %(jc1) %(cc1_options) %{I*} %{!findirect-dispatch:-I%U.zip} \
+ %(jc1) %(cc1_options) %{I*} %{!findirect-dispatch:-faux-classpath %U.zip} \
%(invoke_as)}",
0, 0, 0},
Index: lang.opt
===================================================================
--- lang.opt (revision 115306)
+++ lang.opt (working copy)
@@ -81,6 +81,10 @@
Java JoinedOrMissing RejectNegative
--CLASSPATH Deprecated; use --classpath instead
+faux-classpath
+Java Separate RejectNegative
+; Internal only
+
fassert
Java Var(flag_assert) Init(1)
Permit the use of the assert keyword
Index: lang.c
===================================================================
--- lang.c (revision 115306)
+++ lang.c (working copy)
@@ -1,5 +1,5 @@
/* Java(TM) language-specific utility routines.
- Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
+ Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
Free Software Foundation, Inc.
This file is part of GCC.
@@ -313,6 +313,7 @@
jcf_path_bootclasspath_arg (arg);
break;
+ case OPT_faux_classpath:
case OPT_fclasspath_:
case OPT_fCLASSPATH_:
jcf_path_classpath_arg (arg);