You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Casey Daniell <CD...@realm.com> on 2003/03/04 01:02:12 UTC
RMIC classpath???
I am having a problem with RMIC on the following bit of code. (This was
working until I forked my call to javac earlier today, which is a
requirement on this project.) Help please.
I keep getting:
------------------------ Begin Build output---------------------------------
BUILD FAILED
file:C:/realmutils/build.xml:137: Cannot use SUN rmic, as it is not
available.
A common solution is to set the environment variable JAVA_HOME or CLASSPATH.
Verbose output is:
************** Starting Ant
Apache Ant version 1.5.2 compiled on February 28 2003
Buildfile: build.xml
Detected Java version: 1.3 in: C:/jdk1.3.1_07
Detected OS: Windows XP
can't open C:/jdk1.3.1_07\lib\tzmappings.
parsing buildfile build.xml with URI = file:C:/realmutils/build.xml
Project base dir set to: C:\realmutils
Override ignored for property basedir
Build sequence for target `all' is [clean, prepare, compile, deploy,
javadoc, al
l]
Complete build sequence is [clean, prepare, compile, deploy, javadoc, all,
fast,
allcode]
clean:
[delete] Could not find file
C:\bea\wlserver6.0\config\mydomain\applications\
realmutils.jar to delete.
...
...
...
[javac] C:\realmutils\src\org\apache\tomcat\util\ThreadPool.java
[javac]
C:\realmutils\src\org\apache\tomcat\util\ThreadPoolRunnable.java
[javac] Note: Some input files use or override a deprecated API.
[javac] Note: Recompile with -deprecation for details.
[echo] java.home is C:/jdk1.3.1_07
[rmic] com\realm\utils\cache\composite\CompositeCacheManager.class
added as
com/realm/utils/cache/composite/CompositeCacheManager_Stub.class doesn't
exist.
[rmic] RMI Compiling 1 class to C:\realmutils\build\classes
[rmic] Using SUN rmic compiler
[rmic] Compilation arguments:
[rmic] '-d'
[rmic] 'C:\realmutils\build\classes'
[rmic] '-classpath'
[rmic]
'C:\realmutils\build\classes;C:\jdk1.3.1_07\lib\tools.jar;C:\realmut
ils;C:\tools\lib\isomorph.jar'
[rmic]
[rmic] The ' characters around the executable and arguments are
[rmic] not part of the command.
[rmic] File to be compiled:
com.realm.utils.cache.composite.CompositeCac
heManager
BUILD FAILED
file:C:/realmutils/build.xml:137: Cannot use SUN rmic, as it is not
available.
A common solution is to set the environment variable JAVA_HOME or CLASSPATH.
at
org.apache.tools.ant.taskdefs.rmic.SunRmic.execute(SunRmic.java:97)
at org.apache.tools.ant.taskdefs.Rmic.execute(Rmic.java:520)
at org.apache.tools.ant.Task.perform(Task.java:341)
at org.apache.tools.ant.Target.execute(Target.java:309)
at org.apache.tools.ant.Target.performTasks(Target.java:336)
at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
at org.apache.tools.ant.Main.runBuild(Main.java:609)
at org.apache.tools.ant.Main.start(Main.java:196)
at org.apache.tools.ant.Main.main(Main.java:235)
at MyAnt.main(MyAnt.java:30)
Total time: 13 seconds
------------------------ End Build output---------------------------------
What am I overlooking here:
<!-- Setting up the classpath for java compilation-->
<!-- java.home is resolving correctly to C:\jdk1.3.1\ -->
<path id="java.compile.path">
<fileset dir="${java.home}/lib/" includes="tools.jar"/>
<fileset dir="${basedir}/lib/" includes="**/*.jar"/>
</path>
...
.. <!-- the below doesn't work -->
..
<target name="compile" depends="prepare">
<javac srcdir="${java.compile.srcdir}"
includes="com/**,org/**"
destdir="${build.classes}"
debug="on"
optimize="on"
deprecation="off"
fork="yes">
<classpath refid="java.compile.path"/>
</javac>
<echo message="java.home is ${java.home}"/>
<rmic base="${build.classes}"
classname="com.realm.utils.cache.composite.CompositeCacheManager">
<classpath>
<pathelement location="${java.home}/lib/tools.jar"/>
</classpath>
</rmic>
</target>
----------------------------------------------------------------------------
<!-- This doesn't work either....-->
<target name="compile" depends="prepare">
<javac srcdir="${java.compile.srcdir}"
includes="com/**,org/**"
destdir="${build.classes}"
debug="on"
optimize="on"
deprecation="off"
fork="yes">
<classpath refid="java.compile.path"/>
</javac>
<echo message="java.home is ${java.home}"/>
<rmic base="${build.classes}"
classname="com.realm.utils.cache.composite.CompositeCacheManager">
<classpath="java.compile.path"/>
</rmic>
</target>
Casey B. Daniell
Realm Business Solutions, Inc.
13727 Noel Rd. Suite 800
Dallas, TX 75240
cdaniell@realm.com <ma...@realm.com>
O:(469) 791-1065
C:(512) 589-3667
Re: RMIC classpath???
Posted by Martin <mg...@hotmail.com>.
Casey-
and you have
org\apache\tools\ant\taskdefs\rmic\SunRmic.class
on your CLASSPATH?
M
----- Original Message -----
From: "Casey Daniell" <CD...@realm.com>
To: <us...@ant.apache.org>
Sent: Monday, March 03, 2003 5:02 PM
Subject: RMIC classpath???
> I am having a problem with RMIC on the following bit of code. (This was
> working until I forked my call to javac earlier today, which is a
> requirement on this project.) Help please.
>
> I keep getting:
>
> ------------------------ Begin Build
output---------------------------------
> BUILD FAILED
> file:C:/realmutils/build.xml:137: Cannot use SUN rmic, as it is not
> available.
> A common solution is to set the environment variable JAVA_HOME or
CLASSPATH.
>
> Verbose output is:
> ************** Starting Ant
> Apache Ant version 1.5.2 compiled on February 28 2003
> Buildfile: build.xml
> Detected Java version: 1.3 in: C:/jdk1.3.1_07
> Detected OS: Windows XP
> can't open C:/jdk1.3.1_07\lib\tzmappings.
> parsing buildfile build.xml with URI = file:C:/realmutils/build.xml
> Project base dir set to: C:\realmutils
> Override ignored for property basedir
> Build sequence for target `all' is [clean, prepare, compile, deploy,
> javadoc, al
> l]
> Complete build sequence is [clean, prepare, compile, deploy, javadoc, all,
> fast,
> allcode]
>
> clean:
> [delete] Could not find file
> C:\bea\wlserver6.0\config\mydomain\applications\
> realmutils.jar to delete.
> ...
> ...
> ...
> [javac] C:\realmutils\src\org\apache\tomcat\util\ThreadPool.java
> [javac]
> C:\realmutils\src\org\apache\tomcat\util\ThreadPoolRunnable.java
>
> [javac] Note: Some input files use or override a deprecated API.
> [javac] Note: Recompile with -deprecation for details.
> [echo] java.home is C:/jdk1.3.1_07
> [rmic] com\realm\utils\cache\composite\CompositeCacheManager.class
> added as
> com/realm/utils/cache/composite/CompositeCacheManager_Stub.class doesn't
> exist.
>
> [rmic] RMI Compiling 1 class to C:\realmutils\build\classes
> [rmic] Using SUN rmic compiler
> [rmic] Compilation arguments:
> [rmic] '-d'
> [rmic] 'C:\realmutils\build\classes'
> [rmic] '-classpath'
> [rmic]
> 'C:\realmutils\build\classes;C:\jdk1.3.1_07\lib\tools.jar;C:\realmut
> ils;C:\tools\lib\isomorph.jar'
> [rmic]
> [rmic] The ' characters around the executable and arguments are
> [rmic] not part of the command.
> [rmic] File to be compiled:
> com.realm.utils.cache.composite.CompositeCac
> heManager
>
> BUILD FAILED
> file:C:/realmutils/build.xml:137: Cannot use SUN rmic, as it is not
> available.
> A common solution is to set the environment variable JAVA_HOME or
CLASSPATH.
> at
> org.apache.tools.ant.taskdefs.rmic.SunRmic.execute(SunRmic.java:97)
> at org.apache.tools.ant.taskdefs.Rmic.execute(Rmic.java:520)
> at org.apache.tools.ant.Task.perform(Task.java:341)
> at org.apache.tools.ant.Target.execute(Target.java:309)
> at org.apache.tools.ant.Target.performTasks(Target.java:336)
> at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
> at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
> at org.apache.tools.ant.Main.runBuild(Main.java:609)
> at org.apache.tools.ant.Main.start(Main.java:196)
> at org.apache.tools.ant.Main.main(Main.java:235)
> at MyAnt.main(MyAnt.java:30)
>
> Total time: 13 seconds
>
> ------------------------ End Build output---------------------------------
>
> What am I overlooking here:
> <!-- Setting up the classpath for java compilation-->
> <!-- java.home is resolving correctly to C:\jdk1.3.1\ -->
> <path id="java.compile.path">
> <fileset dir="${java.home}/lib/" includes="tools.jar"/>
> <fileset dir="${basedir}/lib/" includes="**/*.jar"/>
> </path>
> ...
> .. <!-- the below doesn't work -->
> ..
> <target name="compile" depends="prepare">
> <javac srcdir="${java.compile.srcdir}"
> includes="com/**,org/**"
> destdir="${build.classes}"
> debug="on"
> optimize="on"
> deprecation="off"
> fork="yes">
> <classpath refid="java.compile.path"/>
> </javac>
> <echo message="java.home is ${java.home}"/>
> <rmic base="${build.classes}"
>
> classname="com.realm.utils.cache.composite.CompositeCacheManager">
> <classpath>
> <pathelement location="${java.home}/lib/tools.jar"/>
> </classpath>
> </rmic>
> </target>
>
>
> --------------------------------------------------------------------------
--
> <!-- This doesn't work either....-->
>
> <target name="compile" depends="prepare">
> <javac srcdir="${java.compile.srcdir}"
> includes="com/**,org/**"
> destdir="${build.classes}"
> debug="on"
> optimize="on"
> deprecation="off"
> fork="yes">
> <classpath refid="java.compile.path"/>
> </javac>
> <echo message="java.home is ${java.home}"/>
> <rmic base="${build.classes}"
>
> classname="com.realm.utils.cache.composite.CompositeCacheManager">
> <classpath="java.compile.path"/>
> </rmic>
> </target>
>
> Casey B. Daniell
> Realm Business Solutions, Inc.
> 13727 Noel Rd. Suite 800
> Dallas, TX 75240
> cdaniell@realm.com <ma...@realm.com>
> O:(469) 791-1065
> C:(512) 589-3667
>
>