LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-21-2008, 12:57 AM   #1
parani86
LQ Newbie
 
Registered: Jan 2008
Posts: 26

Rep: Reputation: 15
Installation of ANT 1.7.0 & 1.6.5


I got a problem on installing ant 1.7.0 & 1.6.5 on rh linux (version 4)
would u give me the instructions regarding tat.
 
Old 01-21-2008, 01:04 AM   #2
jay73
LQ Guru
 
Registered: Nov 2006
Location: Belgium
Distribution: Ubuntu 11.04, Debian testing
Posts: 5,019

Rep: Reputation: 133Reputation: 133
Go to jpackage.org for all java related applications. Their packages install easily through yum. Don't forget to read the instructions first.
 
Old 01-21-2008, 01:05 AM   #3
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,141

Rep: Reputation: 168Reputation: 168
The installation docs on the Ant home page are pretty good. Have you tried them yet?
 
Old 01-21-2008, 03:17 AM   #4
parani86
LQ Newbie
 
Registered: Jan 2008
Posts: 26

Original Poster
Rep: Reputation: 15
Angry Sorry We Tried Out That !!!

Thanks for ur reply,we hav tried out the installing manual at ANT home page but while
defining JAVA_HOME we got an error


Error: JAVA_HOME is not defined correctly.
We cannot execute /usr/local/jdk-1.5.0_14/bin/java

so sujest me anyother way to install it
 
Old 01-21-2008, 03:31 AM   #5
parani86
LQ Newbie
 
Registered: Jan 2008
Posts: 26

Original Poster
Rep: Reputation: 15
Unhappy

while installing the JPACKAGE rpm file

we got following error


unlocatable packages required by

jaxp_parser_impl ('ant','1.6.5','4jpp')
xml-commons-apis ('ant','1.6.5','4jpp')

so plz help on this
 
Old 01-21-2008, 04:30 AM   #6
jay73
LQ Guru
 
Registered: Nov 2006
Location: Belgium
Distribution: Ubuntu 11.04, Debian testing
Posts: 5,019

Rep: Reputation: 133Reputation: 133
Did you save the correct yum files? And are you installing through yum or are you just downloading the rpms and installing them manually? I recommend the first approach as it will automatically fetch any dependencies (providing, of course, that you are using the proper config files as already suggested). If you are installing manually, you have to download the dependencies yourself and install those first - but they may have their own dependencies so you'd need to get those too, etc. - that can go on for a while until you have all that is needed and it can get pretty annoying. So if you can, use the yum approach, then you'll have none of that.

Note that you should also read the remarks on setting up your jdk the proper way. An unmodified jdk straight from Sun is no good. Getting this right is vital if you are to install any of the other packages without any issues.

Last edited by jay73; 01-21-2008 at 04:32 AM.
 
Old 01-21-2008, 05:15 AM   #7
parani86
LQ Newbie
 
Registered: Jan 2008
Posts: 26

Original Poster
Rep: Reputation: 15
PLZ tell me abt the command

we are manually installing by using the RPM files,so tell me how to use
the YUM command in red hat linux,or plz tell me corresponding command...
 
Old 01-21-2008, 05:34 AM   #8
jay73
LQ Guru
 
Registered: Nov 2006
Location: Belgium
Distribution: Ubuntu 11.04, Debian testing
Posts: 5,019

Rep: Reputation: 133Reputation: 133
http://www.jpackage.org/yum.php

Just select the generic item as well as the one for rhel4. Do not forget to replace "mirror" with the address of an actual mirror and to replace "version" with the version of jpackage you would like to use (1.6, 1.7 or 5.0). The most convenient is to click on the MIRROR link and to follow through to the appropriate directory on the mirror, then copy the address to your yum config file.

If you need software from more than one version, you'll need to make extra entries: same mirror but different version.

And remember to read this on configuring jdk:
http://www.jpackage.org/installation.php
I use the compat method, it's faster though not the recommended method.

Last edited by jay73; 01-21-2008 at 01:16 PM.
 
Old 01-21-2008, 12:24 PM   #9
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,141

Rep: Reputation: 168Reputation: 168
Hopefully the info at jpackage helped you. If you're still having problems, can you post the command you ran to set JAVA_HOME and what is the output of echo $JAVA_HOME ?
 
Old 01-21-2008, 10:56 PM   #10
parani86
LQ Newbie
 
Registered: Jan 2008
Posts: 26

Original Poster
Rep: Reputation: 15
Angry The Result Is This....!!!

Mr.gilead

I Will tell all abt tat wat we had done..

based on the instructions from the ANT manual page i.e

{Only the bin and lib directories are required to run Ant. To install Ant, choose a directory and copy the distribution files there. This directory will be known as ANT_HOME.}


we had extracted the ant file to the path /usr/local

Then the path is /usr/local/apache-ant-1.7.0

Then following the commands found in the manual i.e

{export ANT_HOME=/usr/local/ant
export JAVA_HOME=/usr/local/jdk-1.5.0.05
export PATH=${PATH}:${ANT_HOME}/bin}

we set the paths
the result is

[root@localhost ~]# export ANT_HOME=/usr/local/apache-ant-1.7.0
[root@localhost ~]# echo $ANT_HOME
/usr/local/apache-ant-1.7.0

we set the java home to be,

[root@localhost ~]# export JAVA_HOME=/usr/local/jdk-1.5.0_14
[root@localhost ~]# echo $JAVA_HOME
/usr/local/jdk-1.5.0_14


finally,

[root@localhost ~]# export PATH=${PATH}:${ANT_HOME}/bin
[root@localhost ~]# echo $PATH
/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/
usr/sbin:/usr/bin:/usr/X11R6/bin:/root/bin:/usr/local/apache-ant-1.7.0/bin


after doing all these,if we run ant command from the path
/usr/local/apache-ant-1.7.0/bin

we got the error,

[root@localhost bin]# ant
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/tools/ant/launch/Launcher
[root@localhost bin]# ant -v
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/tools/ant/launch/Launcher

help on this....!!

Last edited by parani86; 01-21-2008 at 10:58 PM.
 
Old 01-21-2008, 11:06 PM   #11
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,141

Rep: Reputation: 168Reputation: 168
According to the info at http://ant.apache.org/faq.html#NoClassDefFoundError, the following commands will show whether the problems is with your CLASSPATH variable:
Code:
unset CLASSPATH
ant -version
 
Old 01-22-2008, 12:19 AM   #12
jay73
LQ Guru
 
Registered: Nov 2006
Location: Belgium
Distribution: Ubuntu 11.04, Debian testing
Posts: 5,019

Rep: Reputation: 133Reputation: 133
Are you sure that jdk5 is compatible with ant7? I vaguely recall getting a similar error message some time ago when I was trying to run tomcat on jdk5.

By the way, what was wrong with the jpackage approach? Why mess with manual installs and paths when the system can do it?
 
Old 01-22-2008, 03:07 AM   #13
parani86
LQ Newbie
 
Registered: Jan 2008
Posts: 26

Original Poster
Rep: Reputation: 15
we tried as u said.but we get the same error ie noclassDefFound
 
Old 01-22-2008, 10:17 AM   #14
jay73
LQ Guru
 
Registered: Nov 2006
Location: Belgium
Distribution: Ubuntu 11.04, Debian testing
Posts: 5,019

Rep: Reputation: 133Reputation: 133
Is ant 1.6.5 still installed? I imagine there could be a conflict between 1.6.5. and 1.7. Or maye I should say that your system may be mixed-up by using part of the one and part of the other. I think you should be able to determine whether there is by setting your ant_home and your path in /etc/profile or your bash_profile rather than from the command line. Always make sure that the new ant is added to the beginning of the path, something that does not happen if you use the command line. Thus, if 1.6.5 is in, say, /usr/local, your system would never get to use 1.7 since it finds 1.6.5 before it gets to the other one.
 
Old 01-23-2008, 01:49 AM   #15
parani86
LQ Newbie
 
Registered: Jan 2008
Posts: 26

Original Poster
Rep: Reputation: 15
Red face Up2date ERROR..

while updating the system using the Up2date we got the following error,



Problem registering system:

Error Class Code: 70
Error Class Info:
All available subscriptions for the requested channel have been exhausted.
Please contact a Red Hat Network Sales associate.
Explanation:
An error has occurred while processing your request. If this problem
persists please enter a bug report at bugzilla.redhat.com.
If you choose to submit the bug report, please be sure to include
details of what you were trying to do when this error occurred and
details on how to reproduce this problem.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
ANT installation directory allelopath Linux - Software 3 09-17-2009 05:42 AM
How to use "ant" from J2EE SDK instead of installed ant in Fedora ? pcuongx Linux - Server 2 02-27-2007 04:45 AM
Tomcat - Apache Ant Installation crazycondor Debian 1 12-20-2006 05:37 AM
Apache Ant - Tomcat Installation crazycondor Linux - Newbie 1 12-16-2006 11:27 PM
Ant & args for java acjt Programming 1 04-25-2004 12:01 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 07:20 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration