aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Bodewig <stefan.bodewig@freenet.de>2017-05-04 20:27:42 +0200
committerEugene Kliuchnikov <eustas@google.com>2017-05-04 20:27:42 +0200
commita015b426832a5d7a0bec500b7a8b1ae9fcd0c6d0 (patch)
treea391c6aaa6723ddb02c4ea70d0a75bfbf2e0164e
parentd00ccae57fa92ee0aaa5a16ee842db19cd282cbd (diff)
downloadbrotli-a015b426832a5d7a0bec500b7a8b1ae9fcd0c6d0.zip
brotli-a015b426832a5d7a0bec500b7a8b1ae9fcd0c6d0.tar.gz
brotli-a015b426832a5d7a0bec500b7a8b1ae9fcd0c6d0.tar.bz2
turn java library into an OSGi bundle (#545)
-rwxr-xr-xjava/org/brotli/dec/pom.xml46
1 files changed, 46 insertions, 0 deletions
diff --git a/java/org/brotli/dec/pom.xml b/java/org/brotli/dec/pom.xml
index 36a9069..2574916 100755
--- a/java/org/brotli/dec/pom.xml
+++ b/java/org/brotli/dec/pom.xml
@@ -13,6 +13,11 @@
<name>${project.groupId}:${project.artifactId}</name>
+ <properties>
+ <manifestdir>${project.build.directory}/osgi</manifestdir>
+ <manifestfile>${manifestdir}/MANIFEST.MF</manifestfile>
+ </properties>
+
<build>
<sourceDirectory>../../..</sourceDirectory>
<testSourceDirectory>../../..</testSourceDirectory>
@@ -74,6 +79,47 @@
</execution>
</executions>
</plugin>
+ <plugin>
+ <groupId>org.apache.felix</groupId>
+ <artifactId>maven-bundle-plugin</artifactId>
+ <version>3.0.1</version>
+ <configuration>
+ <archive>
+ <forced>true</forced>
+ </archive>
+ <excludeDependencies>true</excludeDependencies>
+ <manifestLocation>${manifestdir}</manifestLocation>
+ <instructions>
+ <_nouses>true</_nouses>
+ <Bundle-SymbolicName>org.brotli.${project.artifactId}</Bundle-SymbolicName>
+ <Bundle-Description>${project.description}</Bundle-Description>
+ <Export-Package>org.brotli.dec;version=${project.version};-noimport:=true</Export-Package>
+ <Private-Package></Private-Package>
+ <Import-Package>*</Import-Package>
+ <DynamicImport-Package></DynamicImport-Package>
+ <Bundle-DocURL>${project.url}</Bundle-DocURL>
+ </instructions>
+ </configuration>
+ <executions>
+ <execution>
+ <id>bundle-manifest</id>
+ <phase>process-classes</phase>
+ <goals>
+ <goal>manifest</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-jar-plugin</artifactId>
+ <version>2.5</version>
+ <configuration>
+ <archive>
+ <manifestFile>${manifestfile}</manifestFile>
+ </archive>
+ </configuration>
+ </plugin>
</plugins>
</build>