Trying the prototype

Thomas Jung thomas.andreas.jung at googlemail.com
Sat Aug 7 08:26:32 PDT 2010


Hi Collin,

> 3. Do a full JDK build. On Windows, this can be done, but is not for the
> faint of heart.

One possibility to build the JDK for testing is to setup Linux in
VirtualBox. Building the JDK with Ubuntu in VirtualBox is
straightforward and works as described
(http://hg.openjdk.java.net/lambda/lambda/raw-file/39d81b90b100/README-builds.html.
Only one environment variable is missing to allow source code
download). I suppose this much easier than the whole setup of the
environment for Windows.

Thomas

On 7 August 2010 17:04, Jonathan Gibbons <jonathan.gibbons at oracle.com> wrote:
> Collin,
>
> If you have built langtools by itself, the files in langtools/dist/bin/*
> are scripts to be executed with a system like Cygwin. They are not drop
> in replacements for the binaries in your Java installation on Windows.
>
> On Windows, you have 3 options.
>
> 1. Use Cygwin to run the scripts in dist/bin/javac etc.
>
> 2. There is no magic in those scripts -- they simply run your standard
> JDK 7 installation, putting the jar files in langtools/lib/*.jar on the
> bootclasspath using the java -Xbootclasspath/p: option. This variant of
> the option prepends the jar files to the normal boot classpath. If you
> can figure out how to do that for your preferred execution environment,
> you can do that.
>
> 3. Do a full JDK build. On Windows, this can be done, but is not for the
> faint of heart.
>
> -- Jon
>
>
> On 08/07/2010 06:50 AM, Collin Fagan wrote:
>> Hi Maurizio,
>>
>> I'm think I'm very close to being able to try this out. The compiling (via
>> Netbeans) worked very well and now I have a bin folder with java/javac. My
>> first instinct was to copy these files into the jdk1.7.0\bin folder of the
>> latest snapshot but the file names don't line up, java vs java.exe etc. Am I
>> missing some target platform setting? I'm on Windows 7 64 bit. Then again I
>> could be totally wrong on how I should use these files. Any help would be
>> appreciated.
>>
>> Thanks
>> Collin
>>
>> On Fri, Aug 6, 2010 at 2:54 PM, maurizio cimadamore<
>> maurizio.cimadamore at oracle.com>  wrote:
>>
>>
>>> On 06/08/2010 20:36, Collin Fagan wrote:
>>>
>>>
>>>> Brian Goetz
>>>>
>>>>> There is, however, tremendous value in you actually *trying* the
>>>>>
>>>>>
>>>>>
>>>> prototype.
>>>>
>>>>
>>>>
>>>>> Have you done that?
>>>>>
>>>>>
>>>>>
>>>> I sir have not and would very much like to. Should I just get the latest
>>>> openjdk build (103?) or does Project Lambda have it's own branch? Is there
>>>> a
>>>> page that walks me through compiling from source?
>>>>
>>>> thanks,
>>>>
>>>> Collin
>>>>
>>>>
>>>>
>>>>
>>> Hi Collin
>>> thanks for your interest in project lambda. The easiest way to try the
>>> prototype is to have a JDK binary snapshot available (b103 or greater); you
>>> then need to do the following:
>>>
>>> 1) clone the 'langtools' repository of the lambda branch:
>>>
>>> hg clone http://hg.openjdk.java.net/lambda/lambda/langtools
>>>
>>> [this will create a new 'langtools' folder in your current folder]
>>>
>>> 2) build the compiler
>>>
>>> cd langtools/make
>>>
>>> ant -Dboot.java.home=<PATH_TO_JDK6>  -Dtarget.java.home=<PATH_TO_JDK7>
>>> build-all-tools
>>>
>>> This should compile all tools (javac/javap/javah/javadoc/apt) and should
>>> result in a new folder called 'dist' under the 'langtools' folder. Inside
>>> 'dist' there is a subfolder named 'bin' - inside, you will find the
>>> executables for java/javac that should allow you to compile and execute code
>>> containing lambda expressions.
>>>
>>> [If you like NetBeans, there's a NB project under langtools/make - the
>>> project name is 'langtools' - once the project has been opened in the IDE,
>>> you can simply build everything by pressing F-11, or by selecting 'Build'
>>> from the project contexual menu... however ant options (-Dboot.java.home and
>>> -Dtarget.java.home) still need to be specified manually --- this can be done
>>> by accessing the menu under Tools->Options->Misc->Ant and by inserting the
>>> appropriate value in the text field at the bottom of the tab].
>>>
>>> Maurizio
>>>
>>>
>>>
>>>
>>
>
>
>


More information about the lambda-dev mailing list