I'm trying to run JVoiceXML demo but I'm new to all theses new technologies. I succeed to run the demo except the servlet one (in which one you have to work with tomcat. The problem is: when I try to "ant war", an error appears: "BUILD FAILED C:\Users\a904778\JVoiceXML\V1\demo\org.jvoicexml.demo.helloworldservletdemo\build.xml:113: jvxml.xml.lib doesn't denote a zipfileset or a fileset"
Here's my build.xml :
<project name="HelloWorldServlet" default="war" basedir=".">
<description>
This file builds the 'Hello world' demo for JVoiceXML for a servlet container.
This demo consists of two servlets. The 'HelloWorldServlet' as the initial
servlet greets the user and passes a goodbye message to the next servlet,
the 'GoodbyServlet'.
You will need a servlet container, i.e. tomcat, to run this demo.
You will need to adapt the settings for your servlet container in the file
../personal-props/ant.properties.
Call target checkJEE to check the current settings.
I order to run the demo you will first have to call
ant war
to create a deployable war file. After the installation in you sevlet
container, call
ant run
to run the client.
</description>
<!-- allow the user to override setting in an own propertiesfile. -->
<property file="../personal-props/ant.properties" />
<property file="../config-props/ant.properties" />
<!-- Load the settings for 3rdparty libraries -->
<import file="3rdparty-libs.xml" />
<target name="-setup" depends="-local-3rdparty-setup">
<!-- The component built here-->
<property name="component"
value="org.jvoicexml.demo.helloworldservletdemo"/>
<property name="component.path"
value="org/jvoicexml/demo/helloworldservletdemo"/>
<property name="src" value="src" />
<property name="build" value="classes" />
<property name="config" value="config" />
<property name="dist" value="${jvxml.core.dir}/dist" />
<property name="dist.war" value="${dist}/${component}.war" />
<property name="optimize" value="off" />
<property name="debug" value="on" />
<!-- the used class path -->
<path id="build.classpath">
<fileset refid="log4j.lib" />
<fileset refid="servlet.lib" />
<path refid="jvxml.core.lib" />
</path>
<path id="run.classpath">
<fileset refid="log4j.lib" />
<fileset refid="rhino.lib" />
<path refid="jvxml.core.lib" />
</path>
</target>
<target name="-init" depends="-setup">
<mkdir dir="${build}" />
</target>
<target name="-checkJVoiceXML">
<available classname="org.jvoicexml.JVoiceXml" property="jvoicexml.present" classpathref="build.classpath" />
<fail unless="jvoicexml.present">
Cannot find jvoicexml libraries needed to build this demo.
Build this jar from the main project first.
</fail>
</target>
<target name="checkJEE" description="Check JEE library settings" depends="-init">
<available classname="javax.servlet.http.HttpServlet" property="servlet.available">
<classpath>
<fileset refid="servlet.lib" />
</classpath>
</available>
<fail unless="servlet.available">
Cannot find servlet libraries at '${servlet.lib.dir}'.
Adapt the settings for your servlet container in the file
../personal-props/ant.properties.
</fail>
<echo message="servlet.lib.dir = '${servlet.lib.dir}' usable:${servlet.available}" />
</target>
<target name="clean" description="Remove all compiled and distribution files">
<delete dir="${build}" />
<delete file="${jar.file}" />
<delete file="${war.file}" />
</target>
<target name="compile" depends="-init,-checkJVoiceXML" description="Compile the JAVA sources">
<copy todir="${build}">
<fileset dir="${config}">
<include name="**/*.xml" />
<include name="**/*.properties" />
<include name="**/*.policy" />
</fileset>
</copy>
<echo message="compiling with debug=${debug}, optimize=${optimize}" />
<javac destdir="${build}" optimize="${optimize}" debug="${debug}"
deprecation="on" includeantruntime="false">
<src path="${src}" />
<include name="**/*.java" />
<classpath refid="build.classpath" />
<compilerarg value="-Xlint:unchecked" />
</javac>
</target>
<target name="war" depends="compile" description="Pack all compiled servlet files into a single war">
<war destfile="${dist.war}" webxml="WebContent/WEB-INF/web.xml">
<lib refid="log4j.lib" />
<lib refid="jvxml.xml.lib" />
<classes dir="${build}">
<include name="**/*Servlet.class" />
</classes>
<classes dir="config">
<include name="log4j.xml" />
</classes>
<fileset dir="WebContent">
<include name="*.html" />
<include name="META-INF/**" />
</fileset>
</war>
<echo message="Install ${dist.war} to your servlet container!" />
<echo message="Then call 'ant run' to run the client" />
</target>
<target name="run" description="Run the 'hello world servlet demo' demo" depends="compile">
<java classname="org.jvoicexml.demo.helloworldservletdemo.HelloWorldDemo" fork="true">
<jvmarg value="-Djava.security.policy=${build}/jvoicexml.policy" />
<classpath>
<path refid="run.classpath" />
<pathelement path="${build}" />
</classpath>
<arg value="http://127.0.0.1:8080/helloworldservletdemo/HelloWorld" />
</java>
</target>
<target name="checkstyle" description="Check for JVoiceXML coding standard" depends="compile, -initcheckstyle" if="checkstyle.present">
<property name="checkstyle-target.dir" value="${dist}/checkstyle/${component}" />
<mkdir dir="${checkstyle-target.dir}" />
<property name="checkstyle.data" value="${checkstyle-target.dir}/checkstyle-data.xml" />
<checkstyle config="${jvxml.core.dir}/etc/jvoicexml-checks.xml" failonviolation="false">
<classpath>
<pathelement path="${project.classpath}" />
<pathelement location="${build}" />
</classpath>
<classpath refid="jvxml.core.lib" />
<fileset dir="${src}">
<include name="${component.path}/**/*.java" />
</fileset>
<formatter type="xml" tofile="${checkstyle.data}" />
</checkstyle>
<xslt style="${jvxml.core.dir}/etc/checkstyle-frames.xsl" in="${checkstyle.data}" out="${checkstyle-target.dir}/report.html">
<param name="output.dir" expression="${checkstyle-target.dir}" />
</xslt>
</target>
<target name="all" depends="run, war" description="create binaries" />
</project>
I really try to find out what was the problem, but I didn't. Can someone could help me?
I tried to look in every folder to understand, looked on the internet to understand build.xml files but nothing.
PS: I need this war in order to deploy it on tomcat server
Do not try to run demo. Futhermore, don't try use ANT. The project is now on Github and work a bit. User guide do not give that much info.