You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Chris Doran <cd...@extravision.com> on 2004/01/06 18:18:29 UTC

Ant 1.6 and rmic task

Simple rmi question, am I missing something ?

   <!-- Builds the remote stubs -->
   <target name="rmic">
     <rmic 
base="classes" 
classname="com.pts.generic.framework.remote.EVServiceBaseImpl" />
     <rmic 
base="classes" 
classname="com.pts.generic.evscheduler.remote.EVSchedulerServiceImpl" />
   </target>

Works fine with Ant 1.5.3-1.

With Ant 1.6.0, I get this error:
   rmic:
        [rmic] RMI Compiling 1 class to 
C:\Development\projects\evscheduler\build\classes
        [rmic] error: Invalid class file format: 
C:\Development\projects\evscheduler\build\classes\com\pts\generic\framework\remote\EVServiceBaseImpl.class, 
wrong  version: 46, expected 45
        [rmic] error: Class 
com.pts.generic.framework.remote.EVServiceBaseImpl not found.

But if I manually run rmic from my build directory:

rmic -classpath classes -d classes 
com.pts.generic.framework.remote.EVServiceBaseImpl

It's fine, so the class file 'version' is ok.

Anyone else had such a problem ?

(j2sdk1.4.2 on windows)

------------------------------------------------------
extraVISION Ltd, Manor Park Avenue, Manor Park, Cheshire, WA7 1TL, UK
DDI:  +44 (0)1928 598421
Main: +44 (0)1928 579900
Fax:   +44 (0)1928 579901
Email: cdoran@extravision.com
------------------------------------------------------
www.extravision.com - Building business through email


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


Re: Ant 1.6 and rmic task

Posted by Chris Doran <cd...@extravision.com>.
This is a classpath issue. Using -verbose and looking at the classpath I 
can see  the following:

With Ant 1.5.3, rmic's classpath consists of the ant jars prepended to the 
system classpath, but with 1.6.0 they are appended.

So I added the classpath attribute to my rmic task but this makes no 
difference, the system classpath is still included. Shouldn't the system 
classpath be ignored ?


At 17:18 06/01/2004 +0000, you wrote:
>Simple rmi question, am I missing something ?
>
>   <!-- Builds the remote stubs -->
>   <target name="rmic">
>     <rmic base="classes" 
> classname="com.pts.generic.framework.remote.EVServiceBaseImpl" />
>     <rmic base="classes" 
> classname="com.pts.generic.evscheduler.remote.EVSchedulerServiceImpl" />
>   </target>
>
>Works fine with Ant 1.5.3-1.
>
>With Ant 1.6.0, I get this error:
>   rmic:
>        [rmic] RMI Compiling 1 class to 
> C:\Development\projects\evscheduler\build\classes
>        [rmic] error: Invalid class file format: 
> C:\Development\projects\evscheduler\build\classes\com\pts\generic\framework\remote\EVServiceBaseImpl.class, 
> wrong  version: 46, expected 45
>        [rmic] error: Class 
> com.pts.generic.framework.remote.EVServiceBaseImpl not found.
>
>But if I manually run rmic from my build directory:
>
>rmic -classpath classes -d classes 
>com.pts.generic.framework.remote.EVServiceBaseImpl
>
>It's fine, so the class file 'version' is ok.
>
>Anyone else had such a problem ?
>
>(j2sdk1.4.2 on windows)
>
>------------------------------------------------------
>extraVISION Ltd, Manor Park Avenue, Manor Park, Cheshire, WA7 1TL, UK
>DDI:  +44 (0)1928 598421
>Main: +44 (0)1928 579900
>Fax:   +44 (0)1928 579901
>Email: cdoran@extravision.com
>------------------------------------------------------
>www.extravision.com - Building business through email
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
>For additional commands, e-mail: user-help@ant.apache.org

------------------------------------------------------
extraVISION Ltd, Manor Park Avenue, Manor Park, Cheshire, WA7 1TL, UK
DDI:  +44 (0)1928 598421
Main: +44 (0)1928 579900
Fax:   +44 (0)1928 579901
Email: cdoran@extravision.com
------------------------------------------------------
www.extravision.com - Building business through email


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