bnd icon indicating copy to clipboard operation
bnd copied to clipboard

more lenient osgi.ee=JavaSE for unknown JDKs

Open chrisrueger opened this issue 2 months ago • 6 comments

Closes #6858

Experimental:

For a yet to bnd unknown JDK (e.g. JDK-10000) Instead of

Require-Capability: osgi.ee;filter:="(osgi.ee=UNKNOWN)"

we now create

Require-Capability: osgi.ee;filter:="(&(osgi.ee=JavaSE)(version=9955))"

for a .class file with u2 major_version 10000 (9955 == 10000 - 45)

chrisrueger avatar Oct 06 '25 21:10 chrisrueger

In the advent of regular Java versions released this seems the right approach. In general the EE enum might needs to be revised by:

  1. deprecate it
  2. replace all usages by a new JavaExecutionEnvironment class that can hold a java version and computes what ever is needed from that.

laeubi avatar Oct 27 '25 05:10 laeubi

@chrisrueger I have fired up a task for the AI here maybe it produces something useful as a base-ground:

  • https://github.com/laeubi/bnd/pull/5

laeubi avatar Oct 27 '25 05:10 laeubi

In general the EE enum might needs to be revised by

Just adding that currently there are two enums holding Java versions:

  • aQute.bnd.osgi.Clazz.JAVA
  • aQute.bnd.build.model.EE

chrisrueger avatar Oct 27 '25 06:10 chrisrueger

Selecting a ee from bndrun files is a little hard when there are so many list items available. Maybe we can downsize a little.

peterkir avatar Nov 26 '25 19:11 peterkir

#6858 add enums up to JDK50 #6891

Feel free to downsize whatever I did in https://github.com/bndtools/bnd/pull/6891/files :)

chrisrueger avatar Nov 26 '25 19:11 chrisrueger

Selecting a ee from bndrun files is a little hard when there are so many list items available. Maybe we can downsize a little.

mY recommendation would be to replace dropdowns by a spinner or something instead in the UI

laeubi avatar Nov 27 '25 03:11 laeubi