env.setConfigId(new Artifact(id.getGroupId(), id.getArtifactId() + "-DEPLOYMENT", id.getVersion(), id.getType()));
env.addToBundleClassPath(bundleClassPath);
env.setBundleActivator(null);
env.addDynamicImportPackage("*");
OSGiMetaDataBuilder osgiMetaDataBuilder = new OSGiMetaDataBuilder(bundleContext, new DummyExportPackagesSelector());
try {
osgiMetaDataBuilder.build(env);
} catch (IllegalConfigurationException e) {
throw new DeploymentException(e);
}