On 16:06 Tue 10 Aug , Deepak Bhole wrote:
* Marcin Zajączkowski <mszpak(a)wp.pl> [2010-08-10 15:51]:
> On 2010-08-09 22:46, Deepak Bhole wrote:
> > * Marcin Zajączkowski <mszpak(a)wp.pl> [2010-08-08 04:26]:
> >> Hi,
> >> I have a java desktop application which needs java with Swing. In spec I
> >> was using java-devel, but recently I was noticed by one of the users
> >> that it's resolved (in mock build on Fedora 11) as
> >> (which doesn't have swing).
> >> I could change java-devel to java-devel-openjdk, but it would cause
> >> problems with binary Java package from Sun.
> >> Do you have suggestion what could be used to get java-devel compatible
> >> with Swing library?
> > What is the error you are getting? GCJ has swing classes:
> > $ jar tf /usr/lib/jvm/java-1.5.0-gcj/jre/lib/rt.jar | grep -i javax/swing | wc
> > 1351
> You are right. My post was based on a report one of the users of Jubler
> package. I personally don't use gcj. I recompiled in on Fedora 12 with
> java-1.5.0-gcj-188.8.131.52-29.fc12.x86_64 and I've got:
> [javac] 5. ERROR in
> [javac] a (at line 84)
> [javac] new_window.setLocationByPlatform(false);
> [javac] ^^^^^^^^^^^^^^^^^^^^^
> [javac] The method setLocationByPlatform(boolean) is undefined for
> the type Jubler
> Class Jubler extends JFrame. That method was introduced in Java 1.5. I
> didn't dig deeper, but probably it's not implemented in gcj.
Ah, yes, there are a handful of 1.5 methods/classes that are no in GCJ
Unlucky, it's 1 of only 5 in java.awt:
It's probably quite simple to implement (just don't set the window's
location if it's true, and reset to false from certain methods), but
the Javadocs take some getting your head round.
> I will try with java-devel>=1.6.0. Sun binary package 0:1.6.0 and
> OpenJDK 1:1.6.0 should satisfy that requirement and package should be
> built properly in mock.
Yes, this should work.
> There could be problem for people with Sun Java 1.5, but it is after
> EOL, so should be acceptable.
> Thanks for your replies
> java-devel mailing list
java-devel mailing list
Free Java Software Engineer
Red Hat, Inc. (http://www.redhat.com
Support Free Java!
Contribute to GNU Classpath and the OpenJDK
PGP Key: 94EFD9D8 (http://subkeys.pgp.net
Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8