Return-Path: Delivered-To: apmail-jakarta-ant-user-archive@jakarta.apache.org Received: (qmail 49734 invoked by uid 500); 22 May 2001 07:55:19 -0000 Mailing-List: contact ant-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Reply-To: ant-user@jakarta.apache.org Delivered-To: mailing list ant-user@jakarta.apache.org Received: (qmail 49591 invoked from network); 22 May 2001 07:55:15 -0000 Sender: david Message-ID: <3B0A1B01.1C4ACF76@btconnect.com> Date: Tue, 22 May 2001 08:53:37 +0100 From: David Goodenough X-Mailer: Mozilla 4.75 [en] (X11; U; Linux 2.2.14 i586) X-Accept-Language: en MIME-Version: 1.0 To: ant-user@jakarta.apache.org Subject: Re: Yet again!!!! *&^%$#"! "Couldnt find classic compi ler" References: Content-Type: multipart/mixed; boundary="------------16A4DC513299838D26E6CBA7" X-Spam-Rating: h31.sny.collab.net 1.6.2 0/1000/N This is a multi-part message in MIME format. --------------16A4DC513299838D26E6CBA7 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Stefan Bodewig wrote: > Ben, > > calm down a little, please - and help me create the missing FAQ entry > with your help. It usually boils down to one of the reasons you've > already checked. > > The compiler detection code tries to load sun.tools.javac.Main, which > is part of classes.zip in Sun's JDK 1.1 and tools.jar in later JDKs. > > Ben Hutchison wrote: > > > Yes, my JAVA_HOME is set correctly... > > Could you give us some details here, please. Which OS, what does your > JAVA_HOME point to ... > > > Yes, tools.jar is in my classpath... > > Not necessary if you start Ant using the ant or ant.bat scripts. As > long as tools.jar is in JAVA_HOME/lib/tools.jar the script will pick > it up automatically. > > > Yes, Im using a standard Sun 1.3 distribution... > > In which case Ant would first try to use the "modern" compiler > com.sun.tools.javac.Main. It doesn't seem to find this either. > > > No, I dont have ant.jar in my lib/ext/ directory... > > fine, and nowhere else in your CLASSPATH, right? > > > and finally, > > No, it still not working. > > Bad. > > Which version of Ant are you using? > > Are you sure that the java executable you invoke (when you type java > on the command line) is the same one as the one in JAVA_HOME/bin? > > The "cannot find classic compiler" message will appear if you are > running Kaffee (which you'll find as /usr/bin/java on many Linux > systems) - and I've heard rumors that one can sometimes find a > JAVA.EXE in the Windows system directory (and this one is not related > to the VM you've just installed). > > Stefan I think that there is a more deap seated problem, especially with the IBM 1.3 JDK. The only way I could get the Ant build process to find the modern compiler, was to move tools.jar into jre/lib/ext which should not be necessary. I was using exactly the same classpath as a test program which could find the class (and I added an to test this in the build script). The only difference that I can see, and I have yet to pour over a debug trace, is that Ant has its own class loader. --------------16A4DC513299838D26E6CBA7 Content-Type: text/x-vcard; charset=us-ascii; name="david.goodenough.vcf" Content-Transfer-Encoding: 7bit Content-Description: Card for David Goodenough Content-Disposition: attachment; filename="david.goodenough.vcf" begin:vcard n:Goodenough;David x-mozilla-html:FALSE org:D.G.A. ltd adr:;;;;;; version:2.1 email;internet:David.Goodenough@DGA.co.uk x-mozilla-cpt:;0 fn:David Goodenough end:vcard --------------16A4DC513299838D26E6CBA7--