concept bnd tool in category osgi

appears as: The bnd tool, bnd tool
OSGi in Action: Creating Modular Applications in Java

This is an excerpt from Manning's book OSGi in Action: Creating Modular Applications in Java.

The first option requires patience, but the reward is a thorough understanding of the package structure. It also helps you determine other potential areas that can be turned into bundles. The third option can be quick if the framework gives you the complete list of missing packages on the first attempt, but sometimes it feels like an endless loop of “deploy, test, update.” The second option is a good compromise between the other two. The bnd tool has already analyzed the code base to come up with the list of imports, and you already know that the framework will follow the import constraints listed in the manifest. The structured manifest also means you can write a script to do the hard work for you.

Throughout this book, you’ve been building OSGi bundles with the bnd tool, using Ant to manage the builds. If you’re a fan of Maven, you may be feeling a bit left out at this point, but don’t worry. You can build bundles with Maven using the same bnd instructions, thanks to the maven-bundle-plugin. To build a bundle, all you really need is the ability to customize the JAR manifest; you don’t need to change to an OSGi-specific build system. On the other hand, the more a build system understands about what it’s building, the more it can assist you—so which build systems work particularly well with OSGi?