ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jakob" <ja...@jfix.com>
Subject <exec> task: Unrecognized option: -jar bin/exist/start.jar?
Date Fri, 23 Apr 2004 09:56:06 GMT
Hi,

I am getting an "Unrecognized option" error while trying
to use the <exec> task.

[I am currently exploring all possible methods to use Ant
to store XML documents in eXist, i.e. also the <java> task
and eXist's own <xmldb:store> task, and have a lot of
trouble.  If somebody has done this successfully, please
let me know.]

The target:
----------
<target name="store-cmdline">
 <exec executable="${basedir}\bin\jre\bin\java.exe">
  <arg value="-Dexist.home=${exist.home}"/>
  <arg value="-jar ${exist.home}/start.jar"/>
  <arg value="client"/>
  <arg value="-l"/>
  <arg value="-m /db/imo/codes/fss/fss2001/doc"/>
  <arg value="-p ${basedir}\data\imo\codes\fss\fss2001\doc"/>
 </exec>
</target>

The error:
---------
E:\cvs_out\dy_v0.4>ant -v -buildfile buildexist.xml
store-cmdline
Unable to locate tools.jar. Expected to find it in
E:\cvs_out\dy_v0.4\bin\lib\tools.jar
Apache Ant version 1.6.1 compiled on February 12 2004
Buildfile: buildexist.xml
Detected Java version: 1.4 in: E:\cvs_out\dy_v0.4\bin\jre
Detected OS: Windows 2000
parsing buildfile E:\cvs_out\dy_v0.4\buildexist.xml with
URI = file:///E:/cvs_out/dy_v0.4/buildexist.xml
Project base dir set to: E:\cvs_out\dy_v0.4
parsing buildfile
jar:file:E:\cvs_out\dy_v0.4\bin\exist\exist-optional.jar!/org/exist/ant/antlib.xml
with URI = jar:file:E:\cvs_out\dy_v0.4\bin\exist\
exist-optional.jar!/org/exist/ant/antlib.xml
Build sequence for target `store-cmdline' is [store-cmdline]
Complete build sequence is [store-cmdline, store-java,
store-native, ]

store-cmdline:
     [exec] Current OS is Windows 2000
     [exec] Executing
'E:\cvs_out\dy_v0.4\bin\jre\bin\java.exe' with
arguments:
     [exec] '-Dexist.home=bin/exist'
     [exec] '-jar bin/exist/start.jar'
     [exec] 'client'
     [exec] '-l'
     [exec] '-m /db/imo/codes/fss/fss2001/doc'
     [exec] '-p
E:\cvs_out\dy_v0.4\data\imo\codes\fss\fss2001\doc'
     [exec]
     [exec] The ' characters around the executable and
arguments are
     [exec] not part of the command.
     [exec] Unrecognized option: -jar bin/exist/start.jar
     [exec] Could not create the Java virtual machine.

     [exec] Result: 1
BUILD SUCCESSFUL


Thank you,
Jakob.



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


Mime
View raw message