This message is quite lengthy in response to requests for information. Hopefully this will assist the real engineers in diagnosing why there are problems with the various ant/xindice builds. Realizing this work is unfunded :-), it would be nice if when some of the common files were updated as binary distributions, the supported projects would be re-zipped with the most current versions OR better documentation would be available...just a thought...thanks for the help!
The issue does seem to be ant related. When I initially used a simple example in a directory with a build.xml file and a simple java application, I received the classic compiler message. I reviewed my jar settings system wide and then made sure I was completely up to date with a better understanding of the classpath etc. I configured my system as shown below and the problem was solved in the simple case with ant working as expected. However, in the case of the xindice build, the build routine could never find my java file and instead I ened up with the following variation to the above message: "Unable to find a javac compiler; com.sun.tools.javac.Main is not on the classpath. Perhaps JAVA_HOME does not point to the JDK." Note that the current binary (1.0) of XINDICE uses the following: ant 1.4.1, xerces 1.4.3, xalan 2.0.1, xml-apis 1.0 (apparently w/sixe =77k). XINDICE uses the -classpath set method for execution thereby avoiding my versions of ant (1.5.3-1), xalan (2.5-D.1), xerces (1.4.4), and xml-apis (version unknown w/size of 122 kb). JAVA_HOME is set? yes - to c:\j2sdk %JAVA_HOME%\lib\tools.jar exists? yes %JAVA_HOME%\bin\javac.exe exists? yes Please provide some more details: Value of %JAVA_HOME% c:\j2sdk Version of Ant, running on system 1.4.1 (does not seem to work for XINDICE) 1.5.3-1 (seems to work fine in a simple case) Value of %ANT_HOME% c:\ant if you are running Ant 1.5.1 or greater, the output from 'ant -diagnostics' would be useful as well. The <javac> target from your build file. >From the XINDICE.zip Note - I am using the updated batch files for java 1.4 from the users group and not the ones shipped with the initial download as they are known to be buggy for w2k and 1.4 (believe me, recently I've begun to wish we used LINUX/UNIX). <javac srcdir="${src.dir}" destdir="${build.dir}" classpathref="project.class.path" debug="${compile.debug}" optimize="${compile.optimize}" nowarn="${compile.nowarn}" deprecation="${compile.deprecation}" verbose="${compile.verbose}" /> Ant diagnostics: ------- Ant diagnostics report ------- Apache Ant version 1.5.3 compiled on April 16 2003 ------------------------------------------- Implementation Version (JDK1.2+ only) ------------------------------------------- core tasks : 1.5.3 optional tasks : 1.5.3 ------------------------------------------- ANT_HOME/lib jar listing ------------------------------------------- ant.home: c:\ant ant.jar (737884 bytes) optional.jar (671546 bytes) xercesImpl.jar (885250 bytes) xml-apis.jar (108484 bytes) ------------------------------------------- Tasks availability ------------------------------------------- stlist : Missing dependency com.starbase.starteam.Item telnet : Missing dependency com.oroinc.net.SocketClient ftp : Missing dependency com.oroinc.net.ftp.FTP jdepend : Missing dependency jdepend.xmlui.JDepend script : Missing dependency com.ibm.bsf.BSFException junit : Missing dependency junit.framework.TestListener stcheckin : Missing dependency com.starbase.starteam.Item stcheckout : Missing dependency com.starbase.starteam.Item ------------------------------------------- org.apache.env.Which diagnostics ------------------------------------------- Not available. Download it at http://xml.apache.org/commons/ ------------------------------------------- System properties ------------------------------------------- java.runtime.name : Java(TM) 2 Runtime Environment, Standard Edition sun.boot.library.path : c:\j2sdk\jre\bin java.vm.version : 1.4.1_02-b06 java.vm.vendor : Sun Microsystems Inc. java.vendor.url : http://java.sun.com/ path.separator : ; java.vm.name : Java HotSpot(TM) Client VM file.encoding.pkg : sun.io user.country : US sun.os.patch.level : Service Pack 2 java.vm.specification.name : Java Virtual Machine Specification user.dir : c:\public java.runtime.version : 1.4.1_02-b06 java.awt.graphicsenv : sun.awt.Win32GraphicsEnvironment java.endorsed.dirs : c:\j2sdk\jre\lib\endorsed os.arch : x86 java.io.tmpdir : XXXXINTENTIONALLY MASKED BY USERXXXXX line.separator : java.vm.specification.vendor : Sun Microsystems Inc. user.variant : os.name : Windows 2000 ant.home : c:\ant sun.java2d.fontpath : java.library.path : c:\j2sdk\bin;.;C:\WINNT\System32;C:\WINNT;C:\Program Files\TextPad 4;C:\WINNT\system32;C:\WINNT;C:\WINNT\System32\Wbem;C:\WINNT\system32;C:\WIN NT;C:\WINNT\System32\Wbem;C:\WINNT\system32;C:\WINNT;C:\WINNT\System32\Wbem; C:\WINNT\System32;c:\j2sdk\bin;%XINDICE_HOME%\bin;c:\ant\bin;c:\Program Files\Common Files\Adaptec Shared\System;;c:\j2sdk\bin;c:\xindice\bin;c:\ant\bin;c:\Program Files\Common Files\Adaptec Shared\System;;c:\j2sdk\bin;c:\xindice\bin;c:\ant\bin;c:\Program Files\Common Files\Adaptec Shared\System; java.specification.name : Java Platform API Specification java.class.version : 48.0 java.util.prefs.PreferencesFactory : java.util.prefs.WindowsPreferencesFactory os.version : 5.0 user.home : XXXXINTENTIONALLY MASKED BY USERXXXXX user.timezone : America/Los_Angeles java.awt.printerjob : sun.awt.windows.WPrinterJob file.encoding : Cp1252 java.specification.version : 1.4 java.class.path : c:\j2sdk\lib\tools.jar;c:\ant\lib\xml-apis.jar;c:\ant\lib\xercesImpl.jar;c:\ ant\lib\optional.jar;c:\ant\lib\ant.jar;.;c:\j2sdk\bin;c:\j2sdk\lib\tools.ja r;\lib;\xerces\xerces.jar;\xalan\bin;c:\ant\bin;c:\xindice\java\lib; user.name : XXXXINTENTIONALLY MASKED BY USERXXXXX java.vm.specification.version : 1.0 java.home : c:\j2sdk\jre sun.arch.data.model : 32 user.language : en java.specification.vendor : Sun Microsystems Inc. awt.toolkit : sun.awt.windows.WToolkit java.vm.info : mixed mode java.version : 1.4.1_02 java.ext.dirs : c:\j2sdk\jre\lib\ext sun.boot.class.path : c:\j2sdk\jre\lib\rt.jar;c:\j2sdk\jre\lib\i18n.jar;c:\j2sdk\jre\lib\sunrsasig n.jar;c:\j2sdk\jre\lib\jsse.jar;c:\j2sdk\jre\lib\jce.jar;c:\j2sdk\jre\lib\ch arsets.jar;c:\j2sdk\jre\classes java.vendor : Sun Microsystems Inc. file.separator : \ java.vendor.url.bug : http://java.sun.com/cgi-bin/bugreport.cgi sun.io.unicode.encoding : UnicodeLittle sun.cpu.endian : little sun.cpu.isalist : pentium i486 i386 ant 1.4 attempt: Xindice Build System -------------------- Building with classpath c:\j2sdk\lib\tools.jar;.\java\lib\ant-1.4.1.jar;.\java\lib\examples.jar;.\ja va\lib\infozone-tools.jar;.\java\lib\openorb-1.2.0.jar;.\java\lib\openorb_to ols-1.2.0.jar;.\java\lib\xalan-2.0.1.jar;.\java\lib\xerces-1.4.3.jar;.\java\ lib\xindice.jar;.\java\lib\xml-apis-1.0.jar;.\java\lib\xmldb-sdk.jar;.\java\ lib\xmldb-xupdate.jar;.\java\lib\xmldb.jar Starting Ant... Buildfile: build.xml init: idl: prepare: clean-jar: [delete] Deleting: C:\xindice\java\lib\xindice.jar [delete] Unable to delete file C:\xindice\java\lib\xindice.jar src: [echo] Compiling Source [javac] Modern compiler is not available - using classic compiler [javac] Compiling 324 source files to C:\xindice\java\classes BUILD FAILED c:\xindice\build.xml:123: Cannot use classic compiler, as it is not available A common solution is to set the environment variable JAVA_HOME to your jdk directory. Total time: 1 second ant 1.5 attempt (I copied ant.jar from c:\ant\lib into the XINDICE_HOME\java\lib and deleted ant-1.4.1.jar for the attempt). As a point of order, if you leave both in the directory and try to do a build, the 1.4.1 version is used. Xindice Build System -------------------- Building with classpath c:\j2sdk\lib\tools.jar;.\java\lib\ant.jar;.\java\lib\examples.jar;.\java\lib \infozone-tools.jar;.\java\lib\openorb-1.2.0.jar;.\java\lib\openorb_tools-1. 2.0.jar;.\java\lib\xalan-2.0.1.jar;.\java\lib\xerces-1.4.3.jar;.\java\lib\xi ndice.jar;.\java\lib\xml-apis-1.0.jar;.\java\lib\xmldb-sdk.jar;.\java\lib\xm ldb-xupdate.jar;.\java\lib\xmldb.jar Starting Ant... Buildfile: build.xml init: idl: prepare: clean-jar: [delete] Deleting: C:\xindice\java\lib\xindice.jar [delete] Unable to delete file C:\xindice\java\lib\xindice.jar src: [echo] Compiling Source [javac] Compiling 324 source files to C:\xindice\java\classes BUILD FAILED file:c:/xindice/build.xml:123: Unable to find a javac compiler; com.sun.tools.javac.Main is not on the classpath. Perhaps JAVA_HOME does not point to the JDK Total time: 1 second -----Original Message----- From: Jesse Stockall [mailto:[EMAIL PROTECTED] Sent: Monday, May 05, 2003 5:10 PM To: Ant Users List Subject: RE: cannot use classic compiler message lisves on On Mon, 2003-05-05 at 14:08, Johns, D Eric, MAJ, 101ST, EMB, 698-7407 wrote: > I have not specified anything there -(how do you do this - I have java and > textpad- no IDE). I have ensured my classpath includes > %JAVA_HOME%/lib/tools.jar as well.... > Your classpath should not have %JAVA_HOME%/lib/tools.jar, in fact your classpath is best left empty. Repeating my original questions from my 1st reply: Can you please confirm the following: JAVA_HOME is set? %JAVA_HOME%\lib\tools.jar exists? %JAVA_HOME%\bin\javac.exe exists? Please provide some more details: Value of %JAVA_HOME% Version of Ant, Value of %ANT_HOME% if you are running Ant 1.5.1 or greater, the output from 'ant -diagnostics' would be useful as well. The <javac> target from your build file. -- Jesse Stockall <[EMAIL PROTECTED]> --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]