Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compiling KF with JDK 11 #50

Open
chlarsson opened this issue Nov 7, 2018 · 4 comments
Open

Compiling KF with JDK 11 #50

chlarsson opened this issue Nov 7, 2018 · 4 comments
Labels
bug jdk11 Issues related to JDK11

Comments

@chlarsson
Copy link
Contributor

Compiling KF (in develop) with JDK11 fails due to ASM issues.

New version of asm is required, e.g. asm >= 7

@chlarsson chlarsson added bug jdk11 Issues related to JDK11 labels Nov 7, 2018
@chlarsson chlarsson added this to the Knopflerfish 6.2.0 milestone Nov 7, 2018
@d3bjorn
Copy link
Contributor

d3bjorn commented Apr 28, 2022

This is fixed. asm.version has been changed to 9.3

@d3bjorn
Copy link
Contributor

d3bjorn commented Apr 28, 2022

There seems to be some new errors in osgi_tck when running that with JDK11.

@d3bjorn
Copy link
Contributor

d3bjorn commented May 2, 2022

One problem is the class loader check done in FWProps in order to set org.osgi.supports.framework.extension. This test assumes that the class loader is instanceof URLClassLoader. With JDK8 we have a sun.misc.Launcher.AppClassLoader, which extends java.net.URLClassLoader (which extends java.security.SecureClassLoader). With JDK11 we have a jdk.internal.loader.ClassLoaders.AppClassLoader, which extends jdk.internal.loader.BuiltinClassLoader (which extends java.security.SecureClassLoader). This causes org.osgi.supports.framework.extension to be set to false, which is not allowed for OSGi R4 and later.

If we force org.osgi.supports.framework.extension to be true, we get NoClassDefFoundError from some tests that depend on org/osgi/test/cases/condpermadmin/testcond/TestPostPonedCondition or org.osgi.test.cases.condpermadmin.testcond.TestCondition.

@d3bjorn
Copy link
Contributor

d3bjorn commented May 2, 2022

Another problem is that org.osgi.test.cases.framework.junit.classloading.ClassLoadingTests.testHiddenPackages001 depends on org.omg.CORBA which is not present in JDK11.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug jdk11 Issues related to JDK11
Projects
None yet
Development

No branches or pull requests

2 participants