You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@wicket.apache.org by andrea del bene <an...@libero.it> on 2010/12/05 18:18:49 UTC

Wicket and OpenJdk

Hi,

I'm having some troubles trying to compile Wicket main trunk with 
OpenJdk under Ubuntu 10.10 64 bit. Is there any problem with this Java 
distribution?
The compilation error a get is relative to class ResourceTestPage.java 
at 
testing/wicket-threadtest/src/main/java/org/apache/wicket/threadtest/apps/app1/  
The error message is the following:

testing/wicket-threadtest/src/main/java/org/apache/wicket/threadtest/apps/app1/ResourceTestPage.java:[78,4] 
exception java.io.IOException is never thrown in body of corresponding 
try statement

Everything goes fine under my virtual box with WinXp 32 with Oracle JDK.

Thank you.

Re: Wicket and OpenJdk

Posted by Martin Grigorov <mg...@apache.org>.
On Sun, Dec 5, 2010 at 7:31 PM, Carl-Eric Menzel <cm...@wicketbuch.de>wrote:

> On Sun, 5 Dec 2010 19:09:55 +0100
> Martin Grigorov <mg...@apache.org> wrote:
>
> > Compiling with Oracle JDK 1.6 works fine.
>
> That's interesting. I thought Oracle and OpenJDK were (at least for now)
> compatible.
>
> > Wicket 1.4/1.5 *have* to support JDK 1.5 so we can use anything
> > specific for JDK 1.6.
>
> I know, that's fine with me.
>
> > Andrea, I just changed it to catch Exception instead of IOException.
> > Should be OK for OpenJDK now.
>
> On the other hand, should there be a test that checks for 1.5, just to
> make sure it's compiled with 1.5? Probably more effort than it's worth
> though.
>
Our CI (Hudson) checks that for us.

>
> Carl-Eric
> www.wicketbuch.de
>

Re: Wicket and OpenJdk

Posted by andrea del bene <an...@libero.it>.
According to this post 
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6527962  package 
com.sun.image.codec.jpeg is not part of standard Java platform and is 
not supported by OpenJdk.
> On Sun, 5 Dec 2010 19:09:55 +0100
> Martin Grigorov<mg...@apache.org>  wrote:
>
>> Compiling with Oracle JDK 1.6 works fine.
> That's interesting. I thought Oracle and OpenJDK were (at least for now)
> compatible.
>
>


Re: Wicket and OpenJdk

Posted by Carl-Eric Menzel <cm...@wicketbuch.de>.
On Sun, 5 Dec 2010 19:09:55 +0100
Martin Grigorov <mg...@apache.org> wrote:

> Compiling with Oracle JDK 1.6 works fine.

That's interesting. I thought Oracle and OpenJDK were (at least for now)
compatible.

> Wicket 1.4/1.5 *have* to support JDK 1.5 so we can use anything
> specific for JDK 1.6.

I know, that's fine with me. 

> Andrea, I just changed it to catch Exception instead of IOException.
> Should be OK for OpenJDK now.

On the other hand, should there be a test that checks for 1.5, just to
make sure it's compiled with 1.5? Probably more effort than it's worth
though.

Carl-Eric
www.wicketbuch.de

Re: Wicket and OpenJdk

Posted by andrea del bene <an...@libero.it>.
Ok, thank you very much Martin, now building phase ends successfully.
> Compiling with Oracle JDK 1.6 works fine.
> Wicket 1.4/1.5 *have* to support JDK 1.5 so we can use anything specific
> for JDK 1.6.
>
> Andrea, I just changed it to catch Exception instead of IOException. Should
> be OK for OpenJDK now.
>
> On Sun, Dec 5, 2010 at 6:56 PM, Carl-Eric Menzel<cm...@wicketbuch.de>wrote:
>
>


Re: Wicket and OpenJdk

Posted by Martin Grigorov <mg...@apache.org>.
On Sun, Dec 5, 2010 at 7:09 PM, Martin Grigorov <mg...@apache.org>wrote:

> Compiling with Oracle JDK 1.6 works fine.
> Wicket 1.4/1.5 *have* to support JDK 1.5 so we can use anything specific
> for JDK 1.6.
>
Read as "...can not use .."

>
> Andrea, I just changed it to catch Exception instead of IOException. Should
> be OK for OpenJDK now.
>
> On Sun, Dec 5, 2010 at 6:56 PM, Carl-Eric Menzel <cm...@wicketbuch.de>wrote:
>
>> Wicket won't compile with OpenJDK6. You have to use an 1.5 JDK. I had a
>> proposal to use Maven-Toolchains to solve this, but now I'm using a
>> custom "mvn15" script that uses JDK1.5, like Martin Grigorov (I think)
>> suggested.
>>
>> Maybe the JDK1.5 requirement ought to be documented somewhere.
>>
>> Carl-Eric
>> www.wicketbuch.de
>>
>> On Sun, 5 Dec 2010 18:25:41 +0100
>> Martin Grigorov <mg...@apache.org> wrote:
>>
>> > com.sun.image.codec.jpeg.JPEGImageEncoder.encode(BufferedImage) throws
>> > IOException
>> > with Oracle JDK it prints warning about the usage of com.sun.*
>> >
>> > On Sun, Dec 5, 2010 at 6:18 PM, andrea del bene
>> > <an...@libero.it>wrote:
>> >
>> > > Hi,
>> > >
>> > > I'm having some troubles trying to compile Wicket main trunk with
>> > > OpenJdk under Ubuntu 10.10 64 bit. Is there any problem with this
>> > > Java distribution? The compilation error a get is relative to class
>> > > ResourceTestPage.java at
>> > >
>> testing/wicket-threadtest/src/main/java/org/apache/wicket/threadtest/apps/app1/
>> > > The error message is the following:
>> > >
>> > >
>> testing/wicket-threadtest/src/main/java/org/apache/wicket/threadtest/apps/app1/ResourceTestPage.java:[78,4]
>> > > exception java.io.IOException is never thrown in body of
>> > > corresponding try statement
>> > >
>> > > Everything goes fine under my virtual box with WinXp 32 with Oracle
>> > > JDK.
>> > >
>> > > Thank you.
>> > >
>>
>
>

Re: Wicket and OpenJdk

Posted by Martin Grigorov <mg...@apache.org>.
Compiling with Oracle JDK 1.6 works fine.
Wicket 1.4/1.5 *have* to support JDK 1.5 so we can use anything specific
for JDK 1.6.

Andrea, I just changed it to catch Exception instead of IOException. Should
be OK for OpenJDK now.

On Sun, Dec 5, 2010 at 6:56 PM, Carl-Eric Menzel <cm...@wicketbuch.de>wrote:

> Wicket won't compile with OpenJDK6. You have to use an 1.5 JDK. I had a
> proposal to use Maven-Toolchains to solve this, but now I'm using a
> custom "mvn15" script that uses JDK1.5, like Martin Grigorov (I think)
> suggested.
>
> Maybe the JDK1.5 requirement ought to be documented somewhere.
>
> Carl-Eric
> www.wicketbuch.de
>
> On Sun, 5 Dec 2010 18:25:41 +0100
> Martin Grigorov <mg...@apache.org> wrote:
>
> > com.sun.image.codec.jpeg.JPEGImageEncoder.encode(BufferedImage) throws
> > IOException
> > with Oracle JDK it prints warning about the usage of com.sun.*
> >
> > On Sun, Dec 5, 2010 at 6:18 PM, andrea del bene
> > <an...@libero.it>wrote:
> >
> > > Hi,
> > >
> > > I'm having some troubles trying to compile Wicket main trunk with
> > > OpenJdk under Ubuntu 10.10 64 bit. Is there any problem with this
> > > Java distribution? The compilation error a get is relative to class
> > > ResourceTestPage.java at
> > >
> testing/wicket-threadtest/src/main/java/org/apache/wicket/threadtest/apps/app1/
> > > The error message is the following:
> > >
> > >
> testing/wicket-threadtest/src/main/java/org/apache/wicket/threadtest/apps/app1/ResourceTestPage.java:[78,4]
> > > exception java.io.IOException is never thrown in body of
> > > corresponding try statement
> > >
> > > Everything goes fine under my virtual box with WinXp 32 with Oracle
> > > JDK.
> > >
> > > Thank you.
> > >
>

Re: Wicket and OpenJdk

Posted by Carl-Eric Menzel <cm...@wicketbuch.de>.
Wicket won't compile with OpenJDK6. You have to use an 1.5 JDK. I had a
proposal to use Maven-Toolchains to solve this, but now I'm using a
custom "mvn15" script that uses JDK1.5, like Martin Grigorov (I think)
suggested.

Maybe the JDK1.5 requirement ought to be documented somewhere.

Carl-Eric
www.wicketbuch.de

On Sun, 5 Dec 2010 18:25:41 +0100
Martin Grigorov <mg...@apache.org> wrote:

> com.sun.image.codec.jpeg.JPEGImageEncoder.encode(BufferedImage) throws
> IOException
> with Oracle JDK it prints warning about the usage of com.sun.*
> 
> On Sun, Dec 5, 2010 at 6:18 PM, andrea del bene
> <an...@libero.it>wrote:
> 
> > Hi,
> >
> > I'm having some troubles trying to compile Wicket main trunk with
> > OpenJdk under Ubuntu 10.10 64 bit. Is there any problem with this
> > Java distribution? The compilation error a get is relative to class
> > ResourceTestPage.java at
> > testing/wicket-threadtest/src/main/java/org/apache/wicket/threadtest/apps/app1/
> > The error message is the following:
> >
> > testing/wicket-threadtest/src/main/java/org/apache/wicket/threadtest/apps/app1/ResourceTestPage.java:[78,4]
> > exception java.io.IOException is never thrown in body of
> > corresponding try statement
> >
> > Everything goes fine under my virtual box with WinXp 32 with Oracle
> > JDK.
> >
> > Thank you.
> >

Re: Wicket and OpenJdk

Posted by Martin Grigorov <mg...@apache.org>.
com.sun.image.codec.jpeg.JPEGImageEncoder.encode(BufferedImage) throws
IOException
with Oracle JDK it prints warning about the usage of com.sun.*

On Sun, Dec 5, 2010 at 6:18 PM, andrea del bene <an...@libero.it>wrote:

> Hi,
>
> I'm having some troubles trying to compile Wicket main trunk with OpenJdk
> under Ubuntu 10.10 64 bit. Is there any problem with this Java distribution?
> The compilation error a get is relative to class ResourceTestPage.java at
> testing/wicket-threadtest/src/main/java/org/apache/wicket/threadtest/apps/app1/
>  The error message is the following:
>
> testing/wicket-threadtest/src/main/java/org/apache/wicket/threadtest/apps/app1/ResourceTestPage.java:[78,4]
> exception java.io.IOException is never thrown in body of corresponding try
> statement
>
> Everything goes fine under my virtual box with WinXp 32 with Oracle JDK.
>
> Thank you.
>