@NotNull File manifestTemplate) throws OsgiBuildException {
String inputPath = inputJar.getPath();
ManifestContents manifest;
try {
PropertiesSource propertiesSource = new PropertiesPropertiesSource(properties);
ManifestGenerator generator = new StandardManifestGenerator(DefaultManifestGeneratorContributorsFactory.create(propertiesSource));
ClassPath classPath = new StandardClassPathFactory().create(inputPath);
ManifestContents contents = new StandardManifestTemplateFactory().create(manifestTemplate.getPath(), null, null, null);
manifest = generator.generate(contents, classPath);