Missing Constraint: Import-Package: sun.misc #1981
The Apache NetBeans project has just tried to migrate from version
Java / Android version
NetBeans project builds & runs primarily on JDK8.
NetBeans is using home-made Ant based build system. I don't think it matters for this bug report.
As PR-3200 states: The start of NetBeans fails with exception coming from an OSGi container (Apache NetBeans project is using OSGi behind the scene):
Version 2.8.5 starts. It's manifest doesn't have any unavoidable dependency on
in NetBeans 12.5.
However the new, 2.8.8 version contains explicit dependency on
The Apache NetBeans project doesn't allow OSGi bundles to access
To reproduce I would:
However I assume the problem is clear from the printed error. The
Exception stack trace
OSGi specification defines a special property
works. Yes, we can use it, if necessary. But it puzzles me:
Have you introduced the dependency intentionally? Or is it just an accidental by-product of other changes? I can see that the new version of GSON is built with JDK11 from its JAR manifest. Also the BND tools got upgraded to
Thanks for taking a look and helping Apache NetBeans (possibly others) resolve the upgrade issue.
The text was updated successfully, but these errors were encountered:
* #1981: Avoid OSGi bundle's dependency on sun.misc package * Specify optional dependency on sun.misc.Unsafe * Adjusting the test to sun.misc import being optional * Using Collections.list and for loop * Let the fail message include name of package Co-authored-by: Marcono1234 <Marcono1234@users.noreply.github.com> * Closing the input stream * Dedicated assertSubstring method Co-authored-by: Marcono1234 <Marcono1234@users.noreply.github.com>