Let's be clear... "export" is in manifest for the OSGi framework to know about the packages you provide "packaged" is the inclusion inside the bundle (inlined or not)
Since I first want to understand the mecanics, I though of exporting nothing (for the moment) but I would like to package the uo library so my code can access its classes. Kit Plummer-4 wrote: > > By exported do you mean not packaged in the jar? If so, just add: > > <scope>provided</scope> > > to the <dependency/>. > > If you mean not exported in the MANIFEST - I think it is not by default. > > Kit > > On Nov 28, 2007, at 7:37 AM, Elvy wrote: > >> >> Hi, >> >> I'm new to OSGi and hence, new to the maven-bundle-plugin (2 weeks of >> reading). >> >> I keep on reading posts/docs and can't get the bundle-plugin to >> create an >> (dummy) osgi bundle. >> >> Let's say I have the following java structure: >> com/ >> thalesgroup/ >> osgi/ >> Activator.java >> services/ >> DummyServiceI.java >> >> and I require "uo-1.0.6.jar" (which is a maven project). >> >> First, I would like the bundle to have its uo dependance not exported >> (inlined or not). >> I also need the osgi core jar at compilation but since it is >> exported by >> Felix, it's not needed in the bundle. >> >> Here's my pom >> >> __________________________________________________________________________________________ >> <project xmlns="http://maven.apache.org/POM/4.0.0" >> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" >> xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 >> http://maven.apache.org/maven-v4_0_0.xsd"> >> <modelVersion>4.0.0</modelVersion> >> <name>Stars Tactical Editor OSGi Bundle</name> >> <groupId>com.thalesgroup.osgi</groupId> >> <artifactId>tacticaleditor-bundle</artifactId> >> <version>0.1-SNAPSHOT</version> >> <packaging>bundle</packaging> >> >> <dependencies> >> <dependency> >> <groupId>com.thalesgroup.stars</groupId> >> <artifactId>uo</artifactId> >> <version>1.0.6</version> >> </dependency> >> <dependency> >> <groupId>org.osgi</groupId> >> <artifactId>osgi-core</artifactId> >> <version>4.1</version> >> <!--<scope>provided</scope>--> >> <optional>true</optional> >> </dependency> >> </dependencies> >> >> <build> >> <plugins> >> <plugin> >> <groupId>org.apache.maven.plugins</groupId> >> <artifactId>maven-compiler-plugin</artifactId> >> <configuration> >> <source>1.5</source> >> <target>1.5</target> >> </configuration> >> </plugin> >> <plugin> >> <groupId>org.apache.felix</groupId> >> <artifactId>maven-bundle-plugin</artifactId> >> <version>1.0.0</version> >> <extensions>true</extensions> >> <configuration> >> <manifestLocation>META-INF</manifestLocation> >> <instructions> >> <Bundle-Name>Tactical Editor Bundle</Bundle- >> Name> >> <Bundle-Version>${pom.version}</Bundle-Version> >> <Embed-Dependency>*;inline=true</Embed- >> Dependency> >> <_exportcontents>*</_exportcontents> >> <Import-Package>org.osgi.framework</Import- >> Package> >> >> <Export-Package>com.thalesgroup.osgi.services</Export-Package> >> <!-- to find the Activator --> >> >> <Private-Package>com.thalesgroup.osgi</Private-Package> >> >> <Bundle-Activator>com.thalesgroup.osgi.Activator</Bundle-Activator> >> <Embed-Directory>target/dependency</Embed- >> Directory> >> <Embed-StripGroup>true</Embed-StripGroup> >> </instructions> >> </configuration> >> </plugin> >> <plugin> >> <artifactId>maven-dependency-plugin</artifactId> >> <executions> >> <execution> >> <phase>package</phase> >> <configuration> >> >> <!--<outputDirectory>${project.build.directory}/dependency</ >> outputDirectory>--> >> </configuration> >> <goals> >> <goal>unpack-dependencies</goal> >> </goals> >> </execution> >> </executions> >> </plugin> >> </plugins> >> </build> >> </project> >> __________________________________________________________________________________________ >> >> Can you guys please help me getting started? There are a few guiding >> docs >> out there but they lack the little thing that will get the beginner >> up and >> running. >> >> Thanks in advance. >> -- >> View this message in context: >> http://www.nabble.com/getting-started-but-maven-bundle-plugin-tf4888903.html#a13993464 >> Sent from the Apache Felix - Users mailing list archive at Nabble.com. >> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/getting-started-with-maven-bundle-plugin-tf4888903.html#a13994649 Sent from the Apache Felix - Users mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

