From owner-freebsd-java@FreeBSD.ORG Fri Jan 28 00:33:07 2005 Return-Path: Delivered-To: freebsd-java@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 298DC16A4CE for ; Fri, 28 Jan 2005 00:33:07 +0000 (GMT) Received: from rproxy.gmail.com (rproxy.gmail.com [64.233.170.199]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9999E43D45 for ; Fri, 28 Jan 2005 00:33:06 +0000 (GMT) (envelope-from leafy7382@gmail.com) Received: by rproxy.gmail.com with SMTP id 40so277690rnz for ; Thu, 27 Jan 2005 16:33:06 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:references; b=f0pw7KeSPVLuZfdyrKBRnND/3IpXnJ1DQZuaq4YFqfFZ4/2HNoafxA/su5LF2eKpvNddz1AqtwwKu7vXi86anPnFlrgR7OTz5yOi9rF9JUhyBRYk27mNljEhgSl0M0fM3EZhnQdQraiKvq4T8DeHPA3Kxxd2fSJeeguK8CfFbxE= Received: by 10.38.19.34 with SMTP id 34mr46898rns; Thu, 27 Jan 2005 16:33:06 -0800 (PST) Received: by 10.38.8.79 with HTTP; Thu, 27 Jan 2005 16:33:06 -0800 (PST) Message-ID: Date: Fri, 28 Jan 2005 08:33:06 +0800 From: Jiawei Ye To: freebsd-java@freebsd.org In-Reply-To: <20050127200206.GA11547@arabica.esil.univ-mrs.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit References: <20050127182853.GA94844@osiris.chen.org.nz> <20050127200206.GA11547@arabica.esil.univ-mrs.fr> Subject: Re: Which javac is being used? X-BeenThere: freebsd-java@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Jiawei Ye List-Id: Porting Java to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 28 Jan 2005 00:33:07 -0000 On Thu, 27 Jan 2005 21:02:06 +0100, Herve Quiroz wrote: > But what intrigues me is the fact that both 'java' and 'javac' should > use the same logic to pick a JDK (afterall they are both symlinks of > the same 'javavm' file). Hence whichever JDK is chosen, 'javac -version' > and 'java -version' would output the same version number... > > I'll try to see if I can reproduce the same error as you Jiawey, once > the java/jdk15 build is done on my box (if I don't lack free HD space > until then). > > But in the mean time, here are my quick two cents: > > Is it possible that you use an alias javac->jikes with some > JIKES_BOOTCLASSPATH (or equivalent) set to /usr/local/jdk1.4.2/... > > Jiawei, could you try running the same commands but undefining JAVA_* > beforehand (and just with JAVA_VERSION=1.5 as suggested by Jonathan)? > > Herve I found the problem. If I set JAVA_HOME=${localbase}/jdk1.5.0/jre, 'java' would run jdk1.5.0 vm but 'javac' picks up the wrong version from bsd.port.mk since the executable isn't found in ${JAVA_HOME/bin. Setting JAVA_VERSION=1.5 works. Regards, Jiawei Ye -- "Without the userland, the kernel is useless." --inspired by The Tao of Programming