You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Sylvain Perchaud <sy...@europe-shareware.org> on 2005/09/15 19:15:06 UTC
Newbie question
Hello,
I tried to use Ant (Ant build file created with oXygen) just for a test on my
Windows XP machine.
Unfortunately I cannot even compile my small test, the system is saying me
that some libs are missing. But when I read the libs names, I believe
that these libs are not related at all to what I want to compile.
What is wrong with my Ant or JDK installation ?
Please find below my build file, my java example and the errlog.
Can you help me or point me to a page where a solution to my problem is
described ?
==============
build.xml file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE project SYSTEM "file:/C:/Program%20Files/Oxygen/frameworks/ant/
ant.dtd">
<project default="main">
<target name="main" depends="compile, compress">
<echo>Building the .jar file.</echo>
</target>
<target name="compile">
<javac srcdir="."/>
</target>
<target name="compress">
<jar jarfile="Project.jar" basedir="." includes="*.class"/>
</target>
</project>
=================
Project.java file
public class Project
{ public static void main(String args[])
{
System.out.println("No worries.");
}
}
===========
errlog file
Adding reference: ant.PropertyHelper
Detected Java version: 1.5 in: C:\Program Files\Java\jdk1.5.0_04\jre
Detected OS: Windows XP
Adding reference: ant.ComponentHelper
Setting ro project property: ant.version -> Apache Ant version 1.6.2
compiled on July 16 2004
Setting ro project property: ant.file -> C:\\build.xml
Adding reference: ant.projectHelper
Adding reference: ant.parsing.context
Adding reference: ant.targets
parsing buildfile C:\build.xml with URI = file:///C:/build.xml
resolving systemId: file:/C:/Program%20Files/Oxygen/frameworks/ant/ant.dtd
Setting ro project property: ant.file.null -> C:\build.xml
Project base dir set to: C:\
+Target:
+Target: main
+Target: compile
+Target: compress
Build sequence for target `main' is [compile, compress, main]
Complete build sequence is [compile, compress, main, ]
compile:
Could not load a dependent class (com/sun/media/jai/codec/
FileSeekableStream) for type image
Could not load a dependent class (com/jcraft/jsch/UserInfo) for type sshexec
Could not load a dependent class (com/jcraft/jsch/UserInfo) for type scp
Could not load class (org.apache.tools.ant.tasksdefs.cvslib.CvsVersion)
for type cvsversion
Could not load a dependent class (jdepend/xmlui/JDepend) for type jdepend
Could not load a dependent class (junit/framework/Test) for type junit
fileset: Setup scanner in dir C:\ with patternSet{ includes: [] excludes: [] }
--
Sylvain Perchaud
Tel : +33 (0) 674 758 551
Fax : +33 (0) 251 280 374
http://www.europe-shareware.org
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
Re: Newbie question
Posted by Steve Loughran <st...@apache.org>.
Sylvain Perchaud wrote:
> Le vendredi 16 septembre 2005, à 21:06, Steve Loughran a écrit:
>
>
>><javac> automatically tries to compile all .java files in and under the
>>source directory
>
>
> Right, that was my problem.
> Thanks a lot, I thought about everything but that kind of thing.
>
>
>
ahh, no problem. you are just starting out; it always takes time to
learn to understand the messages that a tool gives,
just be glad you didnt try using anything that used the <delete>
command; you could have found your filesystem a lot emptier than before...
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
Re(2): Newbie question
Posted by Sylvain Perchaud <sy...@europe-shareware.org>.
Le vendredi 16 septembre 2005, à 21:06, Steve Loughran a écrit:
><javac> automatically tries to compile all .java files in and under the
>source directory
Right, that was my problem.
Thanks a lot, I thought about everything but that kind of thing.
--
Sylvain Perchaud
Tel : +33 (0) 674 758 551
Fax : +33 (0) 251 280 374
http://www.europe-shareware.org
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
Re: Newbie question
Posted by Steve Loughran <st...@apache.org>.
Sylvain Perchaud wrote:
> Hello,
>
>
>
> I tried to use Ant (Ant build file created with oXygen) just for a test on my
> Windows XP machine.
>
> Unfortunately I cannot even compile my small test, the system is saying me
> that some libs are missing. But when I read the libs names, I believe
> that these libs are not related at all to what I want to compile.
>
> What is wrong with my Ant or JDK installation ?
> Please find below my build file, my java example and the errlog.
>
>
> Can you help me or point me to a page where a solution to my problem is
> described ?
>
>
>
> ==============
> build.xml file
>
>
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE project SYSTEM "file:/C:/Program%20Files/Oxygen/frameworks/ant/
> ant.dtd">
> <project default="main">
> <target name="main" depends="compile, compress">
> <echo>Building the .jar file.</echo>
> </target>
> <target name="compile">
> <javac srcdir="."/>
> </target>
> <target name="compress">
> <jar jarfile="Project.jar" basedir="." includes="*.class"/>
> </target>
> </project>
>
>
>
>
>
>
> =================
> Project.java file
>
> public class Project
> { public static void main(String args[])
> {
> System.out.println("No worries.");
> }
> }
>
>
>
>
> ===========
> errlog file
>
> Adding reference: ant.PropertyHelper
> Detected Java version: 1.5 in: C:\Program Files\Java\jdk1.5.0_04\jre
> Detected OS: Windows XP
> Adding reference: ant.ComponentHelper
> Setting ro project property: ant.version -> Apache Ant version 1.6.2
> compiled on July 16 2004
> Setting ro project property: ant.file -> C:\\build.xml
> Adding reference: ant.projectHelper
> Adding reference: ant.parsing.context
> Adding reference: ant.targets
> parsing buildfile C:\build.xml with URI = file:///C:/build.xml
> resolving systemId: file:/C:/Program%20Files/Oxygen/frameworks/ant/ant.dtd
> Setting ro project property: ant.file.null -> C:\build.xml
> Project base dir set to: C:\
> +Target:
> +Target: main
> +Target: compile
> +Target: compress
> Build sequence for target `main' is [compile, compress, main]
> Complete build sequence is [compile, compress, main, ]
>
> compile:
> Could not load a dependent class (com/sun/media/jai/codec/
> FileSeekableStream) for type image
> Could not load a dependent class (com/jcraft/jsch/UserInfo) for type sshexec
> Could not load a dependent class (com/jcraft/jsch/UserInfo) for type scp
> Could not load class (org.apache.tools.ant.tasksdefs.cvslib.CvsVersion)
> for type cvsversion
> Could not load a dependent class (jdepend/xmlui/JDepend) for type jdepend
> Could not load a dependent class (junit/framework/Test) for type junit
> fileset: Setup scanner in dir C:\ with patternSet{ includes: [] excludes: [] }
<javac> automatically tries to compile all .java files in and under the
source directory, as that is how you lay out java files in a packaged
structure. So here it is trying to compile every java file it can find
on drive C:, and failing,
work in a private directory and all will be well.
-steve
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
Re(2): Newbie question
Posted by Sylvain Perchaud <sy...@europe-shareware.org>.
Le jeudi 15 septembre 2005, à 13:27, Jeffrey E Care a écrit:
>Does your build actually fail?
in fact my build never ends, I have to stop it.
>These types of messages:
>
>> Could not load a dependent class (com/jcraft/jsch/UserInfo) for type
>sshexec
>> Could not load a dependent class (com/jcraft/jsch/UserInfo) for type scp
>
>are not that unusual and will not actually break your build; they are just
>there to signal that some of the optional tasks will not work due to some
>of their required libraries not being available on the classpath.
That is strange since I installed Ant and the latest JDK and wrote the
first example described in O'Reilly book about Ant.
If even that first example does not work without downloading additional
classes...
--
Sylvain Perchaud
Tel : +33 (0) 674 758 551
Fax : +33 (0) 251 280 374
http://www.europe-shareware.org
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
Re: Newbie question
Posted by Jeffrey E Care <ca...@us.ibm.com>.
Does your build actually fail?
These types of messages:
> Could not load a dependent class (com/jcraft/jsch/UserInfo) for type
sshexec
> Could not load a dependent class (com/jcraft/jsch/UserInfo) for type scp
are not that unusual and will not actually break your build; they are just
there to signal that some of the optional tasks will not work due to some
of their required libraries not being available on the classpath.
--
Jeffrey E. Care (carej@us.ibm.com)
WebSphere v7 Release Engineer
WebSphere Build Tooling Lead (Project Mantis)
"Sylvain Perchaud" <sy...@europe-shareware.org> wrote on 09/15/2005
01:15:06 PM:
> Hello,
>
>
>
> I tried to use Ant (Ant build file created with oXygen) just for a test
on my
> Windows XP machine.
>
> Unfortunately I cannot even compile my small test, the system is saying
me
> that some libs are missing. But when I read the libs names, I believe
> that these libs are not related at all to what I want to compile.
>
> What is wrong with my Ant or JDK installation ?
> Please find below my build file, my java example and the errlog.
>
>
> Can you help me or point me to a page where a solution to my problem is
> described ?
>
>
>
> ==============
> build.xml file
>
>
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE project SYSTEM
"file:/C:/Program%20Files/Oxygen/frameworks/ant/
> ant.dtd">
> <project default="main">
> <target name="main" depends="compile, compress">
> <echo>Building the .jar file.</echo>
> </target>
> <target name="compile">
> <javac srcdir="."/>
> </target>
> <target name="compress">
> <jar jarfile="Project.jar" basedir="." includes="*.class"/>
> </target>
> </project>
>
>
>
>
>
>
> =================
> Project.java file
>
> public class Project
> { public static void main(String args[])
> {
> System.out.println("No worries.");
> }
> }
>
>
>
>
> ===========
> errlog file
>
> Adding reference: ant.PropertyHelper
> Detected Java version: 1.5 in: C:\Program Files\Java\jdk1.5.0_04\jre
> Detected OS: Windows XP
> Adding reference: ant.ComponentHelper
> Setting ro project property: ant.version -> Apache Ant version 1.6.2
> compiled on July 16 2004
> Setting ro project property: ant.file -> C:\\build.xml
> Adding reference: ant.projectHelper
> Adding reference: ant.parsing.context
> Adding reference: ant.targets
> parsing buildfile C:\build.xml with URI = file:///C:/build.xml
> resolving systemId:
file:/C:/Program%20Files/Oxygen/frameworks/ant/ant.dtd
> Setting ro project property: ant.file.null -> C:\build.xml
> Project base dir set to: C:\
> +Target:
> +Target: main
> +Target: compile
> +Target: compress
> Build sequence for target `main' is [compile, compress, main]
> Complete build sequence is [compile, compress, main, ]
>
> compile:
> Could not load a dependent class (com/sun/media/jai/codec/
> FileSeekableStream) for type image
> Could not load a dependent class (com/jcraft/jsch/UserInfo) for type
sshexec
> Could not load a dependent class (com/jcraft/jsch/UserInfo) for type scp
> Could not load class (org.apache.tools.ant.tasksdefs.cvslib.CvsVersion)
> for type cvsversion
> Could not load a dependent class (jdepend/xmlui/JDepend) for type
jdepend
> Could not load a dependent class (junit/framework/Test) for type junit
> fileset: Setup scanner in dir C:\ with patternSet{ includes: []
excludes: [] }
>
>
>
>
>
>
>
>
> --
> Sylvain Perchaud
> Tel : +33 (0) 674 758 551
> Fax : +33 (0) 251 280 374
> http://www.europe-shareware.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>