Return-Path: Delivered-To: apmail-ant-ivy-user-archive@www.apache.org Received: (qmail 65541 invoked from network); 18 Apr 2008 18:36:17 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 18 Apr 2008 18:36:17 -0000 Received: (qmail 64856 invoked by uid 500); 18 Apr 2008 18:36:17 -0000 Delivered-To: apmail-ant-ivy-user-archive@ant.apache.org Received: (qmail 64836 invoked by uid 500); 18 Apr 2008 18:36:17 -0000 Mailing-List: contact ivy-user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: ivy-user@ant.apache.org Delivered-To: mailing list ivy-user@ant.apache.org Received: (qmail 64827 invoked by uid 99); 18 Apr 2008 18:36:17 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 18 Apr 2008 11:36:17 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of tbeattie@boingo.com designates 66.103.64.28 as permitted sender) Received: from [66.103.64.28] (HELO SMTP.CORP.BOINGO.COM) (66.103.64.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 18 Apr 2008 18:35:21 +0000 Received: from [10.103.20.251] (helo=[10.103.20.251]) by SMTP.CORP.BOINGO.COM with esmtp (Exim 4.40) id 1JmvQx-0000CY-N2 for ivy-user@ant.apache.org; Fri, 18 Apr 2008 18:35:39 +0000 Subject: Re: Problem: failed to create task or type antlib:org.apache.ivy.ant:retrieve From: Trevin Beattie To: ivy-user@ant.apache.org In-Reply-To: <136737.95262.qm@web30807.mail.mud.yahoo.com> References: <136737.95262.qm@web30807.mail.mud.yahoo.com> Content-Type: text/plain Organization: Boingo Wireless Date: Fri, 18 Apr 2008 11:35:22 -0700 Message-Id: <1208543722.27099.88.camel@ernie.boingo.com> Mime-Version: 1.0 X-Mailer: Evolution 2.8.3 (2.8.3-2.fc6) Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Bug #35060 appears to have the same symptoms that I'm seeing, but I don't see the resolution for that bug. The poster claims to have moved ant.jar and ant-launcher.jar to /usr/share/java/ant/, but the classpath in the second command line shows that he is still using the ones in /usr/share/java/. In any event, when I copy ant.jar and ant-launcher.jar to /usr/share/java/ant on my system, it has no effect; the build still fails. Another difference I noticed in the two command lines is that one puts all of the jars in the -classpath option, while the other moves everything except ant-launcher.jar over to the -cp option. But that didn't work for me either. In fact, it didn't even work when I added ivy-2.0.0-beta2.jar to -cp (either with the rest of the jars under -cp or -classpath). It only works when I add ivy-2.0.0-beta2.jar to the -classpath option. I tried adding another external task to ~/.ant/lib/, and it didn't work either. I'm going to try debugging the ant launcher, though I have no idea when it's supposed to load the jars... -- Trevin On Thu, 2008-04-17 at 23:20 -0700, Maarten Coene wrote: > Can you use other tasks when you put them in your ~/.ant/lib, or do you have only problems with the ivy.jar? > Maybe your problem is related to https://issues.apache.org/bugzilla/show_bug.cgi?id=35060 ? > > Maarten > > ----- Original Message ---- > From: Trevin Beattie > To: ivy-user@ant.apache.org > Sent: Friday, April 18, 2008 12:44:43 AM > Subject: Re: Problem: failed to create task or type antlib:org.apache.ivy.ant:retrieve > > On Thu, 2008-04-17 at 23:00 +0200, Jacob Grydholt Jensen wrote: > > On 17/04/2008, Trevin Beattie wrote: > > > More details: I downloaded a fresh copy of the source tarballs of both > > > ant-1.6.2 and ant-1.6.5 from archive.apache.org, built them (without any > > > vendor patches), and ran the full command line for each, *without* > > > explicitly adding ivy on the classpath. With ant-1.6.2, the build > > > succeeded. With ant-1.6.5, the build failed. So it looks like ivy is > > > incompatible with newer versions of ant. (1.6.5 is 3 years old, BTW) > > > > I just tested 1.6.5 with 2.0.0-beta2 on Windows XP and it worked fine. > > So it doesn't seem that ivy is incompatible with ant 1.6.5 in general. > > But, it is strange that your combination of OS, ant and ivy does not > > work. What is the output of ant -v (version 1.6.5 and ivy in > > ~/.ant/lib)? I am also curious to see the value of ${user.home}. > > > > Best regards, > > Jacob Grydholt Jensen > > I don't see user.home or any other properties in the '-v' output. But > `ant -diagnostics' shows me: "user.home : /home/tbeattie". Here's the > '-v' output: > > Apache Ant version 1.6.5 compiled on August 30 2006 > Buildfile: build.xml > Detected Java version: 1.5 in: /usr/java/jdk1.6.0_03/jre > Detected OS: Linux > parsing buildfile /home/tbeattie/src/apache-ivy-2.0.0-beta2/src/example/hello-ivy/build.xml with URI = file:///home/tbeattie/src/apache-ivy-2.0.0-beta2/src/example/hello-ivy/build.xml > Project base dir set to: /home/tbeattie/src/apache-ivy-2.0.0-beta2/src/example/hello-ivy > Build sequence for target(s) `run' is [resolve, run] > Complete build sequence is [resolve, run, report, clean, clean-cache, ] > > resolve: > > BUILD FAILED > /home/tbeattie/src/apache-ivy-2.0.0-beta2/src/example/hello-ivy/build.xml:38: Could not create task or type of type: antlib:org.apache.ivy.ant:retrieve. > > Ant could not find the task or a class this task relies upon. > > This is common and has a number of causes; the usual > solutions are to read the manual pages then download and > install needed JAR files, or fix the build file: > - You have misspelt 'antlib:org.apache.ivy.ant:retrieve'. > Fix: check your spelling. > - The task needs an external JAR file to execute > and this is not found at the right place in the classpath. > Fix: check the documentation for dependencies. > Fix: declare the task. > - The task is an Ant optional task and the JAR file and/or libraries > implementing the functionality were not found at the time you > yourself built your installation of Ant from the Ant sources. > Fix: Look in the ANT_HOME/lib for the 'ant-' JAR corresponding to the > task and make sure it contains more than merely a META-INF/MANIFEST.MF. > If all it contains is the manifest, then rebuild Ant with the needed > libraries present in ${ant.home}/lib/optional/ , or alternatively, > download a pre-built release version from apache.org > - The build file was written for a later version of Ant > Fix: upgrade to at least the latest release version of Ant > - The task is not an Ant core or optional task > and needs to be declared using . > - You are attempting to use a task defined using > or but have spelt wrong or not > defined it at the point of use > > Remember that for JAR files to be visible to Ant tasks implemented > in ANT_HOME/lib, the files must be in the same directory or on the > classpath > > Please neither file bug reports on this problem, nor email the > Ant mailing lists, until all of these causes have been explored, > as this is not an Ant bug. > at org.apache.tools.ant.UnknownElement.getNotFoundException(UnknownElement.java:493) > at org.apache.tools.ant.UnknownElement.makeObject(UnknownElement.java:391) > at org.apache.tools.ant.UnknownElement.maybeConfigure(UnknownElement.java:158) > at org.apache.tools.ant.Task.perform(Task.java:363) > at org.apache.tools.ant.Target.execute(Target.java:341) > at org.apache.tools.ant.Target.performTasks(Target.java:369) > at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1216) > at org.apache.tools.ant.Project.executeTarget(Project.java:1185) > at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:40) > at org.apache.tools.ant.Project.executeTargets(Project.java:1068) > at org.apache.tools.ant.Main.runBuild(Main.java:668) > at org.apache.tools.ant.Main.startAnt(Main.java:187) > at org.apache.tools.ant.launch.Launcher.run(Launcher.java:246) > at org.apache.tools.ant.launch.Launcher.main(Launcher.java:67) > > Total time: 0 seconds