1827704 Members
3240 Online
109967 Solutions
New Discussion

Re: Ant command

 
ambika_1
Frequent Advisor

Ant command

Hi,
I am using HP UX 11.11 OS.
When i run Ant its giving following problem.

java.lang.NoClassDefFoundError: org/apache/tools/ant/launch/AntMain
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:539)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:251)
at java.net.URLClassLoader.access$100(URLClassLoader.java:55)
at java.net.URLClassLoader$1.run(URLClassLoader.java:194)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:187)
at java.lang.ClassLoader.loadClass(ClassLoader.java:289)
at java.lang.ClassLoader.loadClass(ClassLoader.java:282)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:274)
at java.lang.ClassLoader.loadClass(ClassLoader.java:282)
at java.lang.ClassLoader.loadClass(ClassLoader.java:235)
at org.apache.tools.ant.launch.Launcher.run(Launcher.java:244)
at org.apache.tools.ant.launch.Launcher.main(Launcher.java:67)


I installed ant from ixAnt_A.06.00-1.6.5_HP-UX_B.11.11_32+64.depot.

So what might be the problem?


5 REPLIES 5
Arunvijai_4
Honored Contributor

Re: Ant command

Hello,

May be .jar file not included in CLASSPATH. Check your ant script in /opt/iexpress/ant/bin. Try to export it again.

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
Muthukumar_5
Honored Contributor

Re: Ant command

Try to search the jar files are available or not. If available put them it CLASSPATH environment. Else download them.

A search with search engine will be helpful always,

http://www.jarhoo.com/jarhoo/JarFileContents.do?jarFileId=1931
http://www.jguru.com/forums/view.jsp?EID=1277775

--
Muthu
Easy to suggest when don't know about the problem!
ambika_1
Frequent Advisor

Re: Ant command

Hi,
I exported jar file path in CLASSPATH. But its giving the same error. All the jar files are there in machine.

Regards,
Ambika

Muthukumar_5
Honored Contributor

Re: Ant command

Can you post the information of,

echo $CLASSPATH in your shell?

If you are having jar files then exporting the location may be the problem. Try to export correctly.

--
Muthu
Easy to suggest when don't know about the problem!
ambika_1
Frequent Advisor

Re: Ant command


Here is the output of echo $CLASSPATH

tajindia# echo $CLASSPATH
/opt/iexpress/ant/lib/ant-antlr.jar:/opt/iexpress/ant/lib/ant-jdepend.jar:/opt/iexpress/ant/lib/ant-weblogic.jar:/opt/iexpress/ant/lib/:/usr/include://opt/iexpress/ant/lib/ant-nodeps.jar:/opt/iexpress/ant/lib/ant.jar:/opt/iexpress/ant/lib/ant-launcher.jar
tajindia#