Return-Path: Delivered-To: apmail-ant-dev-archive@www.apache.org Received: (qmail 61065 invoked from network); 10 Nov 2010 05:17:40 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 10 Nov 2010 05:17:40 -0000 Received: (qmail 1408 invoked by uid 500); 10 Nov 2010 05:18:11 -0000 Delivered-To: apmail-ant-dev-archive@ant.apache.org Received: (qmail 1056 invoked by uid 500); 10 Nov 2010 05:18:09 -0000 Mailing-List: contact dev-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Ant Developers List" Reply-To: "Ant Developers List" Delivered-To: mailing list dev@ant.apache.org Received: (qmail 1048 invoked by uid 99); 10 Nov 2010 05:18:07 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 10 Nov 2010 05:18:07 +0000 X-ASF-Spam-Status: No, hits=0.7 required=10.0 tests=SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [88.84.128.168] (HELO samaflost.de) (88.84.128.168) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 10 Nov 2010 05:18:00 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by samaflost.de (Postfix) with ESMTP id A7D8B40E000A for ; Wed, 10 Nov 2010 06:17:39 +0100 (CET) Received: from samaflost.de ([127.0.0.1]) by localhost (v35516.1blu.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tGC5Qp2GIeHQ for ; Wed, 10 Nov 2010 06:17:39 +0100 (CET) Received: by samaflost.de (Postfix, from userid 1000) id 5E92B40E0009; Wed, 10 Nov 2010 06:17:39 +0100 (CET) From: Stefan Bodewig To: dev@ant.apache.org Subject: Re: issues with ant References: <4CD9A513.7090202@oracle.com> X-Draft-From: ("nnfolder:mail.jakarta-ant" 101641) Date: Wed, 10 Nov 2010 06:17:39 +0100 In-Reply-To: <4CD9A513.7090202@oracle.com> (Ludmila Shikhvarg's message of "Tue, 09 Nov 2010 11:46:27 -0800") Message-ID: <87iq05dafg.fsf@v35516.1blu.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Virus-Checked: Checked by ClamAV on apache.org On 2010-11-09, Ludmila Shikhvarg wrote: > I've discovered some ant's problem during gump testing with jdk7 Thank you for reporting them. It might be a good idea to open bugzilla issues for them. > 1. The projects below failed to compile with jdk7 (1.7.0): > junit, test-junit ... > [javac] javac: target release 1.5 conflicts with default source release 1.7 > Thought, there are should not be jdk dependency This is not really Ant's fault. The projects use a javac task like ... which is translated to a command line javac -target 1.5 ... This works fine with JDK6's javac but causes the error you've cited when run with OpenJDK 7. This is not the first time this happens, the javac developers obviously don't care a bit for backwards compatibility. Ant's DefaultCompilerAdapter contains this code } else if ((assumeJava15() || assumeJava16()) && attributes.getTarget() != null) { String t = attributes.getTarget(); if (t.equals("1.1") || t.equals("1.2") || t.equals("1.3") || t.equals("1.4")) { String s = t; if (t.equals("1.1")) { // 1.5.0 doesn't support -source 1.1 s = "1.2"; } attributes.log("", Project.MSG_WARN); attributes.log(" WARNING", Project.MSG_WARN); attributes.log("", Project.MSG_WARN); attributes.log("The -source switch defaults to 1.5 in JDK 1.5 and 1.6.", Project.MSG_WARN); attributes.log("If you specify -target " + t + " you now must also specify -source " + s + ".", Project.MSG_WARN); attributes.log("Ant will implicitly add -source " + s + " for you. Please change your build file.", Project.MSG_WARN); cmd.createArgument().setValue("-source"); cmd.createArgument().setValue(s); } which implicitly adds a -source 1.2 when running on Java5 or Java6 and the user specified the target attribute but not the source attribute. We'd need similar code to adapt to the new default in OpenJDK7 and a target different from 1.7. Again, this really is javac's fault and Ant can only try to lessen the impact. > 2. Failed to run projects due to: > svn: URL 'http://svn.apache.org/repos/asf/ant/antlibs/ant-vss/trunk' doesn't exist Looks as if the svn:externals on http://svn.apache.org/repos/asf/ant/antlibs/all-trunks is wrong, I'll look into it. Thank you for reporting. > 3. All projects related to bootstrap-ant started to fail from jdk7 > b112 with exception below: > compile-tests: > Created dir: /export/home/dtftest/gump/results/ant/build/testcases > Compiling 287 source files to /export/home/dtftest/gump/results/ant/build/testcases > /export/home/dtftest/gump/results/ant/src/tests/junit/org/apache/tools/ant/taskdefs/SQLExecTest.java:209: NullDriver is not abstract and does not override abstract method getParentLogger() in Driver > public static class NullDriver implements Driver { Ahh, JDBC is changing in backwards incompatible ways again. Even if we fix Ant's tests you will find lots of breaking projects downstream later. I haven't checked the new definition of Driver, let's hope it is possible to implement it in a way that also compiles on JDK 1.4 (which is the minimum version of Java supprted by Ant). Stefan --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org For additional commands, e-mail: dev-help@ant.apache.org