ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Beat Mr Beat je vous prie" <b...@cannabismail.com>
Subject Re: passing $* from shell to ant
Date Tue, 12 Mar 2002 15:43:19 GMT


>Reply-To: "Ant Users List" <ant-user@jakarta.apache.org>
>Date: Mon, 11 Mar 2002 07:56:30 -0800 (PST)
> Diane Holt <holtdl@yahoo.com> Re: passing $* from shell to ant Ant Users List <ant-user@jakarta.apache.org>
>--- Beat Mr Beat je vous prie <beat@cannabismail.com> wrote:
>> I need to pass args to ant for it to pass them to my main class.
>> Of course <arg></arg> tags are great.
>> I've also testes 'ant -Dname=val' syntax.
>
>Try 'ant -Dargs="file1 file2 ... filen" myexec', not a -D for each arg.
> 
>> so... something like this :
>>   <target name="myexec"> 
>>     <java classname="packageA.packageB.Main">
>>       <arg line=${*}/>        <!-- H E R E --> 
>>       <classpath>
>>      <pathelement path="${java.class.path}"/>
>>       </classpath>
>>     </java>
>>   </target>
>
>And change "${*}" to "${args}".
>
>Diane
>
>=====
>(holtdl@yahoo.com)
>
>
>

I still have trouble.
command :
 ant myexec -Dargs="~/logs/helloClient_Ctrace.xml"
My error message :
/home/promo-2002/parradel/CorbaTrace/build.xml:93: java.lang.LinkageError: loader constraints
violated when linking org/xml/sax/Parser class

where line 93 is     <java classname="mypackage.Main">

and whole task is :

  <target name="myexec"> 
    <java classname="mypackage.Main">
    <arg line="${args}"/>
    <classpath>
        <pathelement location="${jar}"/>
     <pathelement path="${java.class.path}"/>
     <pathelement path="${parserSax}"/>
    </classpath>
    </java>
  </target>

Any idea ?







          \_O_
            | \  Beat
          _/ \_



------------------------------------------------------------
YourName@CannabisMail.com for FREE ! http://www.CannabisMail.com


---------------------------------------------------------------------
Express yourself with a super cool email address from BigMailBox.com.
Hundreds of choices. It's free!
http://www.bigmailbox.com
---------------------------------------------------------------------

--
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