velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Geir Magnusson Jr." <ge...@optonline.net>
Subject Re: Problem with the examples/app_examples1 using velocity-1.3-rc1 and JDK1.4.0-b92
Date Tue, 09 Apr 2002 20:20:05 GMT
On 4/9/02 4:12 PM, "wilson wong" <wwong@revacomm.com> wrote:

> Hi,
> 
>   The commons-collections.jar and logkit-1.0.1.jar are already in the
> VELOCITY_HOME\build\lib directory.
> 
> I am using Windows XP. And I got the following message when I
> try to execute VELOCITY_HOME\examples\app_example1\example.bat. The
> following error message is returned.
> 
> E:\apache\velocity-1.3-rc1\examples\app_example1>example.bat
> Using classpath:
> .;..\..\bin\velocity-1.3-rc1.jar;..\..\build\lib\werken.xpath.jar
> Exception in thread "main" java.lang.NoClassDefFoundError:
> org/apache/commons/collections/ExtendedProperties
>       at
> org.apache.velocity.runtime.RuntimeInstance.<init>(RuntimeInstance.java:
> 203)
>       at
> org.apache.velocity.runtime.RuntimeSingleton.<clinit>(RuntimeSingleton.j
> ava:150)
>       at org.apache.velocity.app.Velocity.init(Velocity.java:136)
>       at Example.<init>(Example.java:85)
>       at Example.main(Example.java:159)
> 

The problem is that the velocity jar builds by default w/o the dependencies
included.  You can either copy the dependencies out of the build/lib dir and
put them in your webapp's WEB-INF/lib (or classpath, which is a bad idea...)
or build the velocity jar with included dependencies ...

    ant jar-dep


Which will produce a velocity-dep-1.3.jar in the bin directory...

-- 
Geir Magnusson Jr.                                     geirm@optonline.net
System and Software Consulting
The question is : What is a Mahnamahna?


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


Mime
View raw message