Yes, dots instead of slashes did the trick. Thanks for the help. -----Original Message----- From: Gert Vanthienen [mailto:[email protected]] Sent: Thursday, June 23, 2011 1:13 AM To: [email protected] Subject: Re: Resource-only bundles
L.S., Could you try using dir1.dir2 for the Export-Package configuration instruction? Don't have anything here to try it myself first, but I think that's how we export other configuration entries in our own bundles. Regards, Gert Vanthienen ------------------------ FuseSource Web: http://fusesource.com Blog: http://gertvanthienen.blogspot.com/ On Tue, Jun 21, 2011 at 9:09 PM, Scott Came <[email protected]> wrote: > Is there an example somewhere of a bundle project that includes only > resources (no Java classes) to make them available to other bundles? > > I have a file a.txt. I put it in src/main/resources/dir1/dir2/a.txt. Then I > put this in my pom: > > <build> > <defaultGoal>install</defaultGoal> > <plugins> > <plugin> > <groupId>org.apache.felix</groupId> > > <artifactId>maven-bundle-plugin</artifactId> > <extensions>true</extensions> > <configuration> > <instructions> > > <Export-Package>dir1/dir2</Export-Package> > </instructions> > </configuration> > </plugin> > </plugins> > </build> > > My intention is then to import this package in another bundle, then within > Java code in that other bundle use Pax Classpath to get a stream to a.txt and > process from there. > > But I am blocked at creating the bundle. When I do a mvn install on the > above project/pom, it builds the bundle just fine, and puts dir1/dir2/a.txt > in the bundle jar. But there is no Export Package header in the manifest. > And as you'd expect after I install the bundle and do "headers [bundleid]" I > do not see an Export-Package header there. > > Any ideas as to what I'm doing wrong? > > Thanks. > --Scott >
