From dev-return-35525-apmail-harmony-dev-archive=harmony.apache.org@harmony.apache.org Wed Dec 03 14:17:04 2008 Return-Path: Delivered-To: apmail-harmony-dev-archive@www.apache.org Received: (qmail 13389 invoked from network); 3 Dec 2008 14:17:04 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 3 Dec 2008 14:17:04 -0000 Received: (qmail 30693 invoked by uid 500); 3 Dec 2008 14:17:15 -0000 Delivered-To: apmail-harmony-dev-archive@harmony.apache.org Received: (qmail 30167 invoked by uid 500); 3 Dec 2008 14:17:14 -0000 Mailing-List: contact dev-help@harmony.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@harmony.apache.org Delivered-To: mailing list dev@harmony.apache.org Received: (qmail 30156 invoked by uid 99); 3 Dec 2008 14:17:14 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 03 Dec 2008 06:17:14 -0800 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of xiaofeng.li@gmail.com designates 74.125.44.155 as permitted sender) Received: from [74.125.44.155] (HELO yx-out-1718.google.com) (74.125.44.155) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 03 Dec 2008 14:15:42 +0000 Received: by yx-out-1718.google.com with SMTP id 36so1571904yxh.0 for ; Wed, 03 Dec 2008 06:16:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=z2bXaaCkacbpfkTl6P909NDU3LLGDI91IATPGk9pbps=; b=bPoVtr9+czpzvzZNoMNTCGAPjP79pfTi1zd81do2kun24Nx2KZxiLscNJS+/ljR7zx X/3Atz4oHcVQdKqTs6Lcg5ZIafKrpd4F5JMfEVaXVUxg7IniRMPCgLlUckptwHeeyA05 6p6ZXAuKurBFcQdzSwDpQKoI06b0gGfnDs6SY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=rsZl0l5ukeWlEAOWtZ0vL1wO8a3mdImaLJ/5GV9VDDbysqfX3mT0xIlRZ2HcPLZQZN AqrPc9KKD8QSmZHB325YQTu4C3y0D4GiJ0K3BQR+KuRTbdW1ML+DbrRf/cC1uRHhNDxb 1tlyotjvuuAFftNRmD/Gx+IYbCuzqXrRJE9QE= Received: by 10.142.11.20 with SMTP id 20mr4117983wfk.291.1228313779647; Wed, 03 Dec 2008 06:16:19 -0800 (PST) Received: by 10.143.164.5 with HTTP; Wed, 3 Dec 2008 06:16:19 -0800 (PST) Message-ID: <9623c9a50812030616n5326dd04x2dba9260e3e95576@mail.gmail.com> Date: Wed, 3 Dec 2008 22:16:19 +0800 From: "Xiao-Feng Li" To: dev@harmony.apache.org, Dave@janetdev.org Subject: Re: [general] Ja.NET SE OSS Project In-Reply-To: <5634b003$35507afe$37d831dc$@com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <5634b003$35507afe$37d831dc$@com> X-Virus-Checked: Checked by ClamAV on apache.org On Wed, Dec 3, 2008 at 9:07 PM, Dave wrote: > Hi Xiao-Feng, > Yes, the compiler generates .NET CLR byte code. Of course it is still also > able to generate java byte code as well. > > A Ja.NET SE distribution includes both the Harmony JVM(i.e. DRLVM) as well > as a Ja.NET SE VM adapter that I have developed. The adapter is a small > layer that sits between the compiled .NET version of the class libraries > and the .NET CLR/Framework. It deals with the differences between the two > runtimes. Using options to the Harmony Java launcher you pick what VM > (DRLVM or CLR) you want started. By default, with a Ja.NET SE > distribution, the default VM loaded is the Ja.NET VM adapter/CLR instead of > the DRLVM. You can still load the DRLVM by simply invoking the launcher > with: "java -vmdir:drlvm .....". > > When compiling code, the Ja.NET SE compiler, by default, will generate CLR > CIL in PE files (i.e. .NET Assemblies), instead of Java .class files. I > provide a tool called "bam", that can then be used to "jar" up the created > assemblies into a larger unit (i.e .NET Assembly), for improved performance > when running on .NET. The assemblies/.NET Types generated by javac/bam are > the fully compatible with the rest of .NET, so you are able to incorporate > them with other .NET languages (e.g. C#, VB.NET, etc.) as needed. So for > example, in a C# application you are able to add a reference to > "janet.luni.dll" (i.e. Harmony LUNI module compiled to a .NET assembly) and > use the types in the assembly (e.g. "java.lang.System.out.println("Hello > World!")) as you would expect. And of course the reverse of that is true. > That is, in Java you are able to easily reference .NET types in other > assemblies, created by other languages, by simply including the assemblies > on the classpath to the compiler, and then referencing them in Java as you > normally would. As I mentioned earlier, Ja.NET SE compiler is still capable > of generating Java byte code instead of .NET CIL. You must invoke it with > the "-java" option: "javac -java a/b/c.java", and then you can run the > output on the DRLVM by: "java -vmdir:drlvm a.b.c". > > I'll add some more details on my website to better clarify what technology > approach I've taken!.... Thanks! > > Again, thanks for all your hard work... > > -Dave I see. Thanks for the explanation. Really interesting! Will have a look. Thanks, xiaofeng > ---------------------------------------- > > From: "Xiao-Feng Li" > Sent: Tuesday, December 02, 2008 6:29 PM > To: dev@harmony.apache.org, Dave@janetdev.org > Subject: Re: [general] Ja.NET SE OSS Project > > On Wed, Dec 3, 2008 at 2:35 AM, Dave wrote: >> Hi All, >> I just wanted to take a minute and bring your attention to an OSS > project, >> based on Harmony, I recently started .... Ja.NET (www.janetdev.org). >> >> I am building a Java 5 JDK for .NET (i.e. Ja.NET SE), and I am using >> Harmony, along with other open source software (e.g. Eclipse compiler, >> Mono, etc.) as the basis for the work. The goal of the project is to >> create the development tools and libraries that will enable Java to > become >> a "first class" development and runtime environment for .NET. The Ja.NET > SE >> JDK project is the first thing I have kicked off. The hope is, at some >> point in the "very near future", :-), the Ja.NET SE JDK will give >> developers all the Java development tools they need to develop software > in >> Java for the .NET platform. For example, the Java development tools > would >> enable someone to take existing Java source code (e.g. Ant, Xerces, >> Eclipse, etc.) and easily build it, enhance it with new .NET specific >> features, integrate it with other .NET code and libraries (e.g. C#, > VB.NET, >> WPF, etc.), and then ultimately use/run it on .NET. > > This is cool! > > Dave, what's the technology approach you are taking for Ja.NET JDK? > Does it compile Java code into CLR bytecode running on Mono? I can't > find any document in your website about it. > > Thanks, > xiaofeng > >> I'm making pretty good progress THANKS TO YOU and the great work you > have >> done in building Harmony. Without your effort, I'd be a long way from > where >> I am today! So here is a big THANK YOU for all your hard work and >> dedication to open source Java. >> >> I look forward to working with you where/when it makes sense, and hope > that >> I can contribute in some small way to the success of Harmony in the >> future.... >> >> Best regards, >> >> -Dave >> > > -- > http://xiao-feng.blogspot.com > > > -- http://xiao-feng.blogspot.com