On Wed, Sep 2, 2009 at 8:12 AM, Stuart McCulloch <[email protected]> wrote:
> 2009/9/2 Dmitri Plavjanich <[email protected]> > > > The contents of the embedded jar still gets duplicated inside the bundle. > > > > what exactly are the contents of support-jar? does it contain any > com.foo... > packages? > Yes, there are package overlaps. > because by saying: > > <Private-Package>com.foo.*</Private-Package> > > you're telling Bnd to pull in all classes/resources from any matching > packages and inline them > > if you only want to inline your compiled source and the packages overlap > with the dependency, > then either explicitly list the packages (ie. no wildcard that matches the > dependency contents) > That might not work because of the overlap, i.e. both the bundle and embedded jar have the same packages. > or if you're using the 2.0.0 plugin simply don't include Private-Package at > all and it will calculate > it based on your local source files. > In this case it still pulls in the embedded jar's files; all of them. - Dmitri > > <build> > > <plugins> > > <plugin> > > <groupId>org.apache.felix</groupId> > > <artifactId>maven-bundle-plugin</artifactId> > > <extensions>true</extensions> > > <configuration> > > <instructions> > > > > <Embed-Dependency>support-jar;inline=false</Embed-Dependency> > > <Export-Package>com.foo.api</Export-Package> > > <Private-Package>com.foo.*</Private-Package> > > > > <Bundle-Activator>com.foo.impl.Activator</Bundle-Activator> > > </instructions> > > </configuration> > > </plugin> > > </plugins> > > </build> > > > > <dependencies> > > > > <dependency> > > <groupId>org.papoose.osgi</groupId> > > <artifactId>OSGi_R4_v4.1_core_spec</artifactId> > > <scope>provided</scope> > > </dependency> > > > > <dependency> > > <groupId>com.foo</groupId> > > <artifactId>support-jar</artifactId> > > <scope>runtime</scope> > > </dependency> > > > > </dependencies> > > > > - Dimitri > > > > > > -- > Cheers, Stuart >
