ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rhino" <rhi...@sympatico.ca>
Subject Re: problem with running ant in eclipse
Date Mon, 19 Dec 2005 13:44:27 GMT
I had the same issue yesterday so the solution is still fresh in my mind.

I'm using Eclipse 3.1.1 with Ant 1.6.5 so I'm going to assume that the 
instructions for 3.1.1 will be the same as for 3.1 and whatever version of 
Ant you are using.

You have a decision to make about the placement of your e.jar file:
A. You can put it in the 'lib' directory beneath Ant -or-
B. You can put it somewhere else that is more convenient to you.

There is no strong reason to prefer A over B or vice versa. I tend to put my 
extra jars within Ant's 'lib' directory but that's just me. If you are going 
to go with Option A, use your command prompt or operating system GUI to put 
e.jar in the 'lib' directory beneath Ant. In my case, the path is 
E:\eclipse\plugins\org.apache.ant_1.6.5; the 'lib' directory is directly 
beneath that location. If you want to go with Option B, you don't need to do 
anything else right now.

Then, within Eclipse, go to Window/Preferences. In the Preferences tree, 
select Ant and expand the tree beneath it; click on Runtime. Now in the 
Classpath page of the Runtime settings, make sure that the Ant Home Entries 
contains the path that points to your Ant plugin; in my case (Eclipse 
3.1.1), that is E:\eclipse\plugins\org.apache.ant_1.6.5. (You might have a 
slightly older version of Ant so maybe your plugin is org.apache.ant_1.6.3, 
for example.) If your Ant Home Entries don't point to the Ant plugin 
directory on your system, click the Ant Home button and use the directory 
browser to adjust the Ant Home value until it points to your Ant plugin.

To verify that you did this correctly, expand the Ant Home Entries branch of 
the tree and verify that the jars listed underneath the ant plugin are the 
same as the ones that you see in the 'lib' directory of your Ant plugin, 
using your command line or operating system GUI. All of the same jars should 
be present. If you chose Option A, you should see e.jar in this list, 
otherwise, it won't be there.

If you chose Option A, you can click on OK to close the Preferences window; 
then try the Ant task which uses e.jar. Remember, you may need to write a 
Taskdef if the task is not one of the ones in the core and optional tasks 
lists in the Ant Manual.

If you chose Option B, you need to make your e.jar visible to Ant. You do 
this by clicking on the 'Add External Jars' button in the Classpath tab of 
the Ant Runtime preferences. Use the directory navigator to point to e.jar, 
wherever you put it. Click on OK to close the Preferences window; then try 
the Ant task which uses e.jar. Remember, you may need to write a Taskdef if 
the task is not one of the ones in the core and optional tasks lists in the 
Ant Manual.

Rhino


----- Original Message ----- 
From: "vishakha sawant" <vishakha.sawant@gmail.com>
To: <user@ant.apache.org>
Sent: Monday, December 19, 2005 2:17 AM
Subject: problem with running ant in eclipse


Hi,
I am newbie.  I am using eclipse IDE 3.1 and Ant 1.6. This project is using
hibernate for database persistancy. I have hibernate configuration file
placed in classes/resources folder. I have one e.jar file which uses this
resource file to loadconfiguration of hibernate But after building with ant
tool in eclipse that jar file is not able to get that
hibernate.cfg.xmlfile(hibernate configuration file). please tell me
what should i do? please
help me.
Any tutorial link about eclipse and ant will also do.

Regards,
Vishakha



--------------------------------------------------------------------------------


No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.1.371 / Virus Database: 267.14.1/206 - Release Date: 16/12/2005



-- 
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.371 / Virus Database: 267.14.1/206 - Release Date: 16/12/2005


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message