Return-Path: Delivered-To: apmail-ant-user-archive@www.apache.org Received: (qmail 70081 invoked from network); 18 Feb 2007 01:20:54 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 18 Feb 2007 01:20:54 -0000 Received: (qmail 57163 invoked by uid 500); 18 Feb 2007 01:20:57 -0000 Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 57124 invoked by uid 500); 18 Feb 2007 01:20:57 -0000 Mailing-List: contact user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Ant Users List" Reply-To: "Ant Users List" Delivered-To: mailing list user@ant.apache.org Received: (qmail 57113 invoked by uid 99); 18 Feb 2007 01:20:57 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 17 Feb 2007 17:20:57 -0800 X-ASF-Spam-Status: No, hits=1.4 required=10.0 tests=SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (herse.apache.org: 206.18.177.53 is neither permitted nor denied by domain of hoju@visi.com) Received: from [206.18.177.53] (HELO alnrmhc13.comcast.net) (206.18.177.53) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 17 Feb 2007 17:20:45 -0800 Received: from nicki.visi.com (c-24-131-157-61.hsd1.nh.comcast.net[24.131.157.61]) by comcast.net (alnrmhc13) with SMTP id <20070218012021b13001i2lee>; Sun, 18 Feb 2007 01:20:21 +0000 X-Mailer: QUALCOMM Windows Eudora Version 7.1.0.9 Date: Sat, 17 Feb 2007 19:20:45 -0600 To: "Ant Users List" From: Jacob Kjome Subject: Re: Ant 1.7.0 can't find Junit in ${user.home}/.ant/lib In-Reply-To: <62FCC5FC-9AA2-4AF4-AD37-92BE85367C0F@gmx.de> References: <20070210174604.C02CE10FB00A@herse.apache.org> <62FCC5FC-9AA2-4AF4-AD37-92BE85367C0F@gmx.de> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed X-Relayed-By: GPGrelay Version 0.959 (Win32) X-Virus-Checked: Checked by ClamAV on apache.org Message-Id: <20070218012048.C322410FB010@herse.apache.org> Hi Antoine, Have you had a chance to try this out? Are you able to reproduce my findings? Jake At 10:14 PM 2/10/2007, you wrote: >Hello Jake, > >I remember that the code concerning translating File to URL has been >kind of 90% rewritten between 1.6.5 and 1.7.0, and delegates more to >the JDK than before. > >I should have a look at your bug report on my computer in the office >which has XP. I just need to download JDK 1.3. > >Regards, > >Antoine > >On Feb 10, 2007, at 12:45 PM, Jacob Kjome wrote: > >> At 02:00 PM 2/9/2007, you wrote: >> >On 2/9/07, Burgess, Benjamin wrote: >> >> Sounds like something I have seen before: >> >> >> >> http://sourceforge.net/tracker/index.php? >> func=detail&aid=1468822&group_i >> >> d=130558&atid=720017 >> >> >> >> Basically, java.net.URL.getFile() had a bug that would return an >> >> incorrect String if the file is not on the same windows drive >> letter as >> >> the working directory. >> >> >> >> Ben >> >> >> >> -----Original Message----- >> >> From: Jacob Kjome [mailto:hoju@visi.com] >> >> Sent: Friday, February 09, 2007 11:36 AM >> >> To: Ant Users List >> >> Subject: Re: Ant 1.7.0 can't find Junit in ${user.home}/.ant/lib >> >> >> >> >> >> I am using Windows. And it works just fine with Ant-1.6.5 no >> matter the >> >> JDK. >> >> But under JDK1.3.1 with Ant-1.7.0, it fails (but works with >> JDK1.6). My >> >> user >> >> home is like any normal windows machine.... >> >> >> >> C:\Documents and Settings\jkjome\.ant\lib >> >> >> >> And when I copy junit.jar from my .ant/lib to ${ant.home}/lib, >> it works >> >> just >> >> fine. Here's my ant.home.... >> >> >> >> D:\java\apache-ant-1.7.0 >> >> >> >> >> >> Can someone with a Windows machine try this? Really, I'm not >> making >> >> this up. >> > >> >Can you file a bug with the information - it is >> >most likely a bug in the jdk like that described by Benjamin. >> >Ant may be able to work around it. >> > >> >As a work-around with Ant 1.7.0, one can place >> >the junit.jar file in the classpath element of the >> >junit task - so perhaps >> > >> > >> > >> > >> > >> >May work? >> > >> >> I've reported it: >> http://issues.apache.org/bugzilla/show_bug.cgi?id=41587 >> >> The work around is easier than that. Just put it in ${ant.home}/ >> lib and it works fine no matter the JDK, no matter the Ant >> version. Remember Ant-1.6.5 **always** works no matter where >> junit.jar is and no matter the JDK. It tried putting the build >> file on my C:\ drive, the same drive as ${user.home}/.ant/lib and >> it didn't make any difference. Of course, Ant itself is on my E:\ >> drive, so I don't know if that makes a difference, but it doesn't >> matter for Ant-1.6.5, so I don't know why it should for Ant-1.7.0? >> Seems to me it's a bug in the Ant-1.7.0 task, but it >> only shows its ugly head under certain conditions, such as under >> JDK1.3.1 on a WinXP box. >> >> >> Jake >> >> >Peter >> > >> > >> >> >> >> Jake >> >> >> >> Quoting Peter Reilly : >> >> >> >> > I have tested with JDK 1.3 and it works: >> >> > ~/learning/a/junit> ant -debug >> >> > Apache Ant version 1.7.0 compiled on December 13 2006 >> >> > Buildfile: build.xml >> >> > Adding reference: ant.PropertyHelper >> >> > Detected Java version: 1.3 in: /usr/java/jdk1.3.1_18/jre >> >> > Detected OS: Linux >> >> > Adding reference: ant.ComponentHelper >> >> > Setting ro project property: ant.file -> >> >> > /home/reilly/learning/a/junit/build.xml >> >> > Adding reference: ant.projectHelper >> >> > Adding reference: ant.parsing.context >> >> > Adding reference: ant.targets >> >> > parsing buildfile /home/reilly/learning/a/junit/build.xml with >> URI = >> >> > file:///home/reilly/learning/a/junit/build.xml >> >> > Project base dir set to: /home/reilly/learning/a/junit >> >> > +Target: >> >> > +Target: -check.junit.exists >> >> > +Target: -check.junit >> >> > +Target: build.something >> >> > Attempting to create object of type >> >> > org.apache.tools.ant.helper.DefaultExecutor >> >> > Adding reference: ant.executor >> >> > Build sequence for target(s) `build.something' is >> >> > [-check.junit.exists, -check.junit, build.something] >> >> > Complete build sequence is [-check.junit.exists, -check.junit, >> >> > build.something, ] >> >> > >> >> > -check.junit.exists: >> >> > [antlib:org.apache.tools.ant] Could not load definitions from >> resource >> >> > org/apache/tools/ant/antlib.xml. It could not be found. >> >> > Setting project property: junit.exists -> true >> >> > >> >> > -check.junit: >> >> > Skipped because property 'junit.exists' set. >> >> > >> >> > build.something: >> >> > >> >> > BUILD SUCCESSFUL >> >> > Total time: 0 seconds >> >> > >> >> > >> >> > Are you running on windows? >> >> > If so there may be the usual problems with spaces and >> >> > perhaps the location of user.home. >> >> > >> >> > Peter >> >> > >> >> > On 2/9/07, Jacob Kjome wrote: >> >> > > >> >> > > Hi Peter, >> >> > > >> >> > > Can you take another look at this? I apologize that I did >> not point >> >> > > it out in the original email, but the problem is >> specifically with >> >> > > older JVM's such as JDK1.3.1. I happened to be using it for >> >> building >> >> > > the project where I found the problem. I just didn't >> realize it was >> >> > > specific to JDK1.3.1 until I tried with JDK1.6. I only >> tried JDK1.6 >> >> > > after you failed to reproduce the behavior and I saw you >> were using >> >> JDK1.5. >> >> > > >> >> > > I think this got lost in the shuffle of the current >> religious debate >> >> > > over whether XML is a scripting language. How about we fix >> this >> >> > > issue first and then move on to that never-ending debate. BTW, >> >> > > everyone realizes that the Gant project exists, right? >> >> > > >> >> > > http://groovy.codehaus.org/Gant >> >> > > >> >> > > >> >> > > Jake >> >> > > >> >> > > At 10:27 AM 2/7/2007, you wrote: >> >> > > > >> >> > > >Hi Peter, >> >> > > > >> >> > > >I narrowed it down. Indeed, your findings are correct.... >> for JDK >> >> > > >1.5 (or JDK 1.6 on my machine). Try it under JDK 1.3.1. >> That's >> >> when >> >> > > >it fails to find Junit.jar unless junit.jar is under >> >> > > >${ant.home}/lib. Not sure about JDK 1.4.x since I don't >> care to >> >> install >> >> > it. >> >> > > > >> >> > > >Jake >> >> > > > >> >> > > >At 02:57 AM 2/7/2007, you wrote: >> >> > > > >Just tested with ant 1.7.0 and this does not happen >> >> > > > >for me - the available does find junit in ~/.ant/lib >> >> > > > > >> >> > > > >build.xml: >> >> > > > > >> >> > > > > >> >> > > > > > >> > > > > property="junit.exists" value="true"/> >> >> > > > > >> >> > > > > >> >> > > > > > >> > > > > unless="junit.exists"> >> >> > > > > JUnit is not currently available to the build >> >> environment. >> >> > > > > Because of this, all targets that require JUnit >> will be >> >> skipped. >> >> > To >> >> > > > > enable these targets, place a copy of JUnit (get >> latest >> >> version >> >> > at >> >> > > > > http://www.junit.org/) in ANT_HOME/lib. >> >> > > > > >> >> > > > > >> >> > > > > >> >> > > > > > >> > if="junit.exists"> >> >> > > > > >> >> > > > > >> >> > > > > >> >> > > > >~/learning/a/junit> ls -l ~/.ant/lib >> >> > > > >total 128 >> >> > > > >-rw-r--r-- 1 reilly ccgrp01 120640 Feb 7 2007 >> junit-3.8.2.jar >> >> > > > >~/learning/a/junit> ant -debug >> >> > > > >Apache Ant version 1.7.0 compiled on December 13 2006 >> >> > > > >Buildfile: build.xml >> >> > > > >Adding reference: ant.PropertyHelper >> >> > > > >Detected Java version: 1.5 in: /usr/java/jdk1.5.0_09/jre >> >> > > > >Detected OS: Linux >> >> > > > >Adding reference: ant.ComponentHelper >> >> > > > >Setting ro project property: ant.file -> >> >> > > > >/home/reilly/learning/a/junit/build.xml >> >> > > > >Adding reference: ant.projectHelper >> >> > > > >Adding reference: ant.parsing.context >> >> > > > >Adding reference: ant.targets >> >> > > > >parsing buildfile /home/reilly/learning/a/junit/ >> build.xml with >> >> URI = >> >> > > > >file:/home/reilly/learning/a/junit/build.xml >> >> > > > >Project base dir set to: /home/reilly/learning/a/junit >> >> > > > > +Target: >> >> > > > > +Target: -check.junit.exists >> >> > > > > +Target: -check.junit >> >> > > > > +Target: build.something >> >> > > > >Attempting to create object of type >> >> > > >org.apache.tools.ant.helper.DefaultExecutor >> >> > > > >Adding reference: ant.executor >> >> > > > >Build sequence for target(s) `build.something' is >> >> > > > >[-check.junit.exists, -check.junit, build.something] >> >> > > > >Complete build sequence is [-check.junit.exists, - >> check.junit, >> >> > > > >build.something, ] >> >> > > > > >> >> > > > >-check.junit.exists: >> >> > > > >[antlib:org.apache.tools.ant] Could not load definitions >> from >> >> resource >> >> > > > >org/apache/tools/ant/antlib.xml. It could not be found. >> >> > > > >Setting project property: junit.exists -> true >> >> > > > > >> >> > > > >-check.junit: >> >> > > > >Skipped because property 'junit.exists' set. >> >> > > > > >> >> > > > >build.something: >> >> > > > > >> >> > > > >BUILD SUCCESSFUL >> >> > > > >Total time: 0 seconds >> >> > > > >~/learning/a/junit> rm ~/.ant/lib/junit-3.8.2.jar >> >> > > > >~/learning/a/junit> ant >> >> > > > >Buildfile: build.xml >> >> > > > > >> >> > > > >-check.junit.exists: >> >> > > > > >> >> > > > >-check.junit: >> >> > > > > [echo] JUnit is not currently available to the build >> >> environment. >> >> > > > > [echo] Because of this, all targets that require >> >> JUnit will >> >> > > > >be skipped. To >> >> > > > > [echo] enable these targets, place a copy of >> JUnit >> >> (get >> >> > > > >latest version at >> >> > > > > [echo] http://www.junit.org/) in ANT_HOME/lib. >> >> > > > > >> >> > > > >build.something: >> >> > > > > >> >> > > > >BUILD SUCCESSFUL >> >> > > > >Total time: 0 seconds >> >> > > > >~/learning/a/junit> >> >> > > > > >> >> > > > >Peter >> >> > > > > >> >> > > > > >> >> > > > > >> >> > > > >On 2/7/07, Jacob Kjome wrote: >> >> > > > >> >> >> > > > >> Maybe this is a known issue, but it appears that >> Junit.jar >> >> must be in >> >> > > > >> ${ant.home}/lib in order to be discovered, at least by >> the >> >> > > > >> task using Ant-1.7.0. In Ant-1.6.5, Junit is >> >> found just >> >> > > > >> fine in ${user.home}/.ant/lib, but not in Ant-1.7.0. For >> >> instance... >> >> > > > >> >> >> > > > >> >> >> > > > >> > >> > > > >> property="junit.exists" value="true"/> >> >> > > > >> >> >> > > > >> >> >> > > > >> > >> > > > >> unless="junit.exists"> >> >> > > > >> JUnit is not currently available to the build >> >> environment. >> >> > > > >> Because of this, all targets that require JUnit will be >> >> skipped. To >> >> > > > >> enable these targets, place a copy of JUnit (get latest >> >> version at >> >> > > > >> http://www.junit.org/) in ANT_HOME/lib. >> >> > > > >> >> >> > > > >> >> >> > > > >> >> >> > > > >> > >> > > if="junit.exists"> >> >> > > > >> ...... >> >> > > > >> >> >> > > > >> >> >> > > > >> >> >> > > > >> With junit.jar in ${user.home}/.ant/lib and using >> Ant-1.7.0, I >> >> always >> >> > > > >> get the message. If I move junit.jar to >> >> ${ant.home}/lib, I >> >> > > > >> don't get the message. Ant-1.6.5 doesn't care >> where I >> >> put >> >> > > > >> it. It finds junit.jar in either location. >> >> > > > >> >> >> > > > >> Is this a known issue? Has it already been fixed for >> >> Ant-1.7.1? >> >> > > > >> >> >> > > > >> >> >> > > > >> Jake >> >> > > > >> >> >> > > > >> >> >> > > > >> >> >> >> --------------------------------------------------------------------- >> >> > > > >> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org >> >> > > > >> For additional commands, e-mail: user-help@ant.apache.org >> >> > > > >> >> >> > > > >> >> >> > > > > >> >> > > > >> >> >> >--------------------------------------------------------------------- >> >> > > > >To unsubscribe, e-mail: user-unsubscribe@ant.apache.org >> >> > > > >For additional commands, e-mail: user-help@ant.apache.org >> >> > > > > >> >> > > > > >> >> > > > > >> >> > > > >> >> > > > >> >> > > >> >> >> >--------------------------------------------------------------------- >> >> > > >To unsubscribe, e-mail: user-unsubscribe@ant.apache.org >> >> > > >For additional commands, e-mail: user-help@ant.apache.org >> >> > > > >> >> > > > >> >> > > > >> >> > > >> >> > > >> >> > > >> >> >> --------------------------------------------------------------------- >> >> > > To unsubscribe, e-mail: user-unsubscribe@ant.apache.org >> >> > > For additional commands, e-mail: user-help@ant.apache.org >> >> > > >> >> > > >> >> > >> >> > >> --------------------------------------------------------------------- >> >> > To unsubscribe, e-mail: user-unsubscribe@ant.apache.org >> >> > For additional commands, e-mail: user-help@ant.apache.org >> >> > >> >> >> >> >> >> >> >> >> >> >> --------------------------------------------------------------------- >> >> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org >> >> For additional commands, e-mail: user-help@ant.apache.org >> >> >> >> >> >> >> >> ************************************************************** >> >> This message, including any attachments, contains confidential >> >information intended for a specific individual and purpose, and is >> >protected by law. If you are not the intended recipient, please >> >contact sender immediately by reply e-mail and destroy all copies. >> >You are hereby notified that any disclosure, copying, or distribution >> >of this message, or the taking of any action based on it, is strictly >> >prohibited. >> >> TIAA-CREF >> >> ************************************************************** >> >> >> >> >> >> >> --------------------------------------------------------------------- >> >> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org >> >> For additional commands, e-mail: user-help@ant.apache.org >> >> >> >> >> > >> >--------------------------------------------------------------------- >> >To unsubscribe, e-mail: user-unsubscribe@ant.apache.org >> >For additional commands, e-mail: user-help@ant.apache.org >> > >> > >> > >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org >> For additional commands, e-mail: user-help@ant.apache.org > > >--------------------------------------------------------------------- >To unsubscribe, e-mail: user-unsubscribe@ant.apache.org >For additional commands, e-mail: user-help@ant.apache.org > > > --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org