ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From John Niven <John.Ni...@marcat.com>
Subject RE: Problems with deploying to Tomcat
Date Tue, 14 May 2002 15:34:27 GMT
> -----Original Message-----
> From: Makarand Bhandari [mailto:maky29@yahoo.com] 
> Sent: 14 May 2002 16:24
> To: Ant Users List
> Subject: RE: Problems with deploying to Tomcat
> 
> 
> The jar that I need in lib gets created by the same
> ant task ! A set of beans and other objects that some
> command line programs share with the jsp's.

Mak,

Could you not refactor your build.xml so that the jar is created before you
build the webapp?  As an example, my build file targets go something like
this:
"get src"
"build classes" [depends: "get src"]
"build jar"     [depends: "build classes"]
"get webapp src"
"get jar"       [depends: "build jar"]
"build webapp"  [depends: "get webapp src", "get jar"]
"war webapp"    [depends: "build webapp"]

The "build webapp" target grabs the webapp structure, inserts the
WEB-INF/lib directory, inserts the latest possible version of the jar into
the new directory.

Incidentally, it seems to me that the problems you were having were because
the structure of your deployed war file did not match the structure of the
unpacked war: by copying WEB-INF/lib into the unpacked war, you broke the
correlation.  I don't know it that's correct, but it (kind of) makes sense
to me... ;)

> 
> I may be getting out of context here, but I'm on this
> track because I was unable to include these jars in my
> tomcat classpath. I'm on HP-UX and just couldn't
> figure out how to make tomcat know where to pick up
> the files from. Moving them in lib worked for me but
> then deployment became a hassel.
> 

Why/how did deployment become a hassle?  Is there any chance you could use
Tomcat's manager application, either from a browser or from Ant, to simplify
the process?

> Any idea of how to get them in tomcat classpath ? 
> Maybe this is the wrong list but an answer here would
> solve my ant problems to :-)
> 
> Thanks..   Mak
> 

Hope something here helps,
Best of luck
John

 --
John Niven
Please reply through mailing list

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


Mime
View raw message