view patches/ant-1.8.0.patch @ 1728:e78e331c336a

Fix Ant 1.8.0 diagnostics issue. 2010-03-31 Andrew John Hughes <ahughes@redhat.com> * Makefile.am: Add Ant patch. * NEWS: Mention Ant patch. * patches/ant-1.8.0.patch: Fix for Ant -diagnostics with Ant 1.8.0 http://hg.openjdk.java.net/jdk7/tl/langtools/rev/de6375751eb7
author Andrew John Hughes <ahughes@redhat.com>
date Wed, 31 Mar 2010 22:57:45 +0100
parents
children
line wrap: on
line source


# HG changeset patch
# User ohair
# Date 1269668224 25200
# Node ID de6375751eb789306126ccfa23a8145bf43af828
# Parent 65e422bbb9841febf9bfa706322b0870711fe6a0
6938326: Use of "ant -diagnostics" a problem with ant 1.8.0, exit code 1 now
Reviewed-by: jjg

--- openjdk.orig/langtools/make/Makefile	Wed Mar 24 17:02:35 2010 -0700
+++ openjdk/langtools/make/Makefile	Fri Mar 26 22:37:04 2010 -0700
@@ -188,10 +188,16 @@ clobber: clean
 # All ant targets of interest
 ANT_TARGETS = build clean sanity post-sanity diagnostics # for now
 
+# Create diagnostics log (careful, ant 1.8.0 -diagnostics always does an exit 1)
+$(OUTPUTDIR)/build/ant-diagnostics.log:
+	@mkdir -p $(OUTPUTDIR)/build $(ANT_TMPDIR)
+	@$(RM) $@
+	$(ANT_JAVA_HOME) $(ANT_OPTS) $(ANT) -diagnostics > $@ ; \
+	  $(ANT_JAVA_HOME) $(ANT_OPTS) $(ANT) -version >> $@
+
 # Create a make target for each
-$(ANT_TARGETS):
+$(ANT_TARGETS): $(OUTPUTDIR)/build/ant-diagnostics.log
 	@ mkdir -p $(OUTPUTDIR)/build $(ANT_TMPDIR)
-	$(ANT_JAVA_HOME) $(ANT_OPTS) $(ANT) -diagnostics > $(OUTPUTDIR)/build/ant-diagnostics.log
 	$(ANT_JAVA_HOME) $(ANT_OPTS) $(ANT) $(ANT_OPTIONS) $@
 
 #-------------------------------------------------------------------