9

I have the following bnd file:

Bundle-Version: 1.0.12
Bundle-Activator: a.b.Activator
Private-Package: a.b
-buildpath: osgi.core;version=4.3.0,\
    org.apache.felix.bundlerepository;version=1.6.6,\
    osgi.cmpn;version=4.3.0.201111022214
-sources: false

In the generated MANIFEST.MF:

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

I don't want this there... there's no reason I can see that it should be. So how do I avoid it?

Dan Gravell
  • 7,855
  • 7
  • 41
  • 64

1 Answers1

13

bnd 2.3 automatically adds this. You can disable with -noee=true in your bnd file.

Generally this is a good requirement to have since it expresses the base JRE requirement of your bundle. bnd determines the version based upon the class file versions in the bundle.

BJ Hargrave
  • 9,324
  • 1
  • 19
  • 27
  • 1
    Ah yeah - sorry this is a "unbounded" version range so it means 1.6 and later... so my concern that this would require _exactly_ 1.6 is invalid. D'oh. – Dan Gravell Sep 16 '14 at 10:23
  • 11
    If you are wondering how to do that with the `maven-bundle-plugin`, use the following instruction: <_noee>true<_noee> – viphe Nov 14 '14 at 19:05
  • 6
    Great this works! You're missing a slash here. So when you're copy/pasting use this instead: <_noee>true – Henno Vermeulen Aug 12 '15 at 07:55