[oe] openjdk-8 runtime failure with x11

Randy Mortensen randy.mort at gmail.com
Tue Nov 1 02:26:57 UTC 2016


> On Oct 23, 2016, at 7:01 PM, Randy Mortensen <randy.mort at gmail.com> wrote:
> 
> Using yocto jethro and meta-java to build openjdk-8 but when running a java swing app, it fails with the following:
> 
> Exception in thread "main" java.awt.AWTError: Toolkit not found: sun.awt.X11.XToolkit followed by a stack trace.
> 
> It seems openjdk-8 is being built without X11 support?
> Is there a fix or known workaround?

do you have 'x11' in your DISTRO_FEATURES as well as PACKAGECONFIG for
openjdk ? if not then it wont enable this support

may be you can add a little bbappend in your layer to add x11 to
PACKAGECONFIG or via local.conf

PACKAGECONFIG_append_pn-openjdk = " x11"

- - - - - - -
Thanks for the response. x11 is in the distro but I’ve had no luck in getting openjdk to honour x11 as a build option. 
I’ve tried your suggestion (but the build failed) and setting EXTRA_OECONF += “ —with-x —disable-headless “
The EXTRA_OECONF options appear in log.do_configure but they seem to be overridden by later options which disable headful.
It seems I need to somehow remove the “—disable-headful” option that is baked into openjdk somewhere but my attempts have failed.

Any other suggestions or guidance are welcome.

> Thanks
> -- 
> _______________________________________________
> Openembedded-devel mailing list
> Openembedded-devel at lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-devel




More information about the Openembedded-devel mailing list