Creates a Maven POM to wrap a third-party jar as an OSGi bundle, use -o to overwrite an existing wrapper. When this script is used outside of a Pax-Construct project, it creates a standalone POM.
| -DaddVersion | add the library version to the wrapper directory |
| -DwrapTransitive | create wrappers for transitive dependencies |
| -DwrapOptional | also create wrappers for optional dependencies |
| -Dexclusions=groupId:artifactId,... | exclude these artifacts from being wrapped |
| -DembedTransitive | embed transitive dependencies inside the wrapper |
| -DincludeResource=directive | Include-Resource BND directive |
| -DimportPackage=directive | Import-Package BND directive |
| -DexportContents=directive | -exportcontents BND directive |
| -DrequireBundle=directive | Require-Bundle BND directive |
| -DdynamicImport=directive | DynamicImport-Package BND directive |
| -DnoUses | don't add any "uses:=" to the generated exports |
| -DtestMetadata=false | disable exhaustive OSGi bundle detection |
| -DbundleName=name | provide a customized name to the new bundle |
| -DbundleGroupId=groupId | provide a customized groupId to the new bundle |
| -DbundleVersion=version | provide a customized version to the new bundle |
| -DparentId=groupId:artifactId | look for a different parent POM |
| -DtargetDirectory=path | alternative location of the wrapper |
| -Dcontents=groupId:artifactId:version,... | include content from selected archetypes |
| -DremoteRepositories=url list | where to download the wrapper archetype(s) |
| -DarchetypeVersion=version | use a different release of the Pax archetype |
| -DattachPom=false | don't add this wrapper as a module |
| -DcompactIds=false | don't try to combine name segments |
-DparentId is useful when you want to link the new wrapper into an existing non Pax-Construct project.
pax-wrap-jar -a backport-util-concurrent -v 3.0 -- -DaddVersion "-DimportPackage=sun.misc;resolution:=optional,*" pax-wrap-jar -a commons-logging -v 1.1 -- -DwrapTransitive "-DimportPackage=javax.*|com.sun.jdmk.comm;resolution:=optional,*" pax-wrap-jar -g org.testng -a testng -c jdk15