Oh, sorry, I wasn't aware of that. The following snippet might help: <plugin> <groupId>org.apache.felix</groupId> <artifactId>maven-bundle-plugin</artifactId> <version>4.2.0</version> <extensions>true</extensions> <configuration> <instructions> <Export-Package> !lib.*, !*-*, * </Export-Package> <Embed-Dependency>*;scope=compile|runtime;inline=true</Embed-Dependency> <Embed-StripGroup>true</Embed-StripGroup> <Embed-Transitive>true</Embed-Transitive> <Import-Package/> </instructions> </configuration> </plugin>
This configuration tells the maven-bundle-plugin not to export packages from the lib folder and packages containing a hyphen somewhere. I have never used native code in bundles before, but have a look at the "Bundle-NativeCode" tag. Regards, Jens Gesendet: Montag, 13. Mai 2019 um 12:09 Uhr Von: "support" <supp...@stitchmastery.com> An: users@felix.apache.org Betreff: Re: maven-bundle-plugin invalid package name error But these are not Java package names. It seems that maven-bundle-plugin is generating them from the contents of the jar but this is the jar contents;- On 11 May 2019, at 19:00, wolle5...@gmx.de[mailto:wolle5...@gmx.de] wrote: I don't think the problem is related to maven-bundle-plugin. You cannot use a hyphen (-) in Java package names. Drop it, use an underscore or whatever. It is up to you. org.bytedeco.opencv.windows-x86 -> org.bytedeco.opencv.windows_x86 org.bytedeco.opencv.macosx-x86_64.include.opencv4.opencv2 -> org.bytedeco.opencv.macosx_x86_64.include.opencv4.opencv2 Regards, Jens Gesendet: Samstag, 11. Mai 2019 um 16:48 Uhr Von: "support" <supp...@stitchmastery.com[mailto:supp...@stitchmastery.com]> An: users@felix.apache.org[mailto:users@felix.apache.org] Betreff: maven-bundle-plugin invalid package name error I am trying to use maven-bundle-plugin to build a bundle for javacv but get errors indicating ‘invalid package name’. This is my POM;- <project xmlns="http://maven.apache.org/POM/4.0.0[http://maven.apache.org/POM/4.0.0]" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance[http://www.w3.org/2001/XMLSchema-instance]" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0[http://maven.apache.org/POM/4.0.0] http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>com.vogella.tycho.plugin4</groupId> <artifactId>com.vogella.tycho.plugin4</artifactId> <version>0.0.1-SNAPSHOT</version> <packaging>bundle</packaging> <build> <plugins> <plugin> <groupId>org.apache.felix</groupId> <artifactId>maven-bundle-plugin</artifactId> <version>3.0.1</version> <extensions>true</extensions> <configuration> <instructions> <Export-Package>*</Export-Package> <Embed-Dependency>*;scope=compile|runtime;inline=false</Embed-Dependency> <Embed-StripGroup>true</Embed-StripGroup> <Embed-Transitive>true</Embed-Transitive> <Import-Package></Import-Package> </instructions> </configuration> </plugin> </plugins> </build> <dependencies> <dependency> <groupId>org.bytedeco</groupId> <artifactId>javacv-platform</artifactId> <version>1.5</version> </dependency> </dependencies> </project> and the error messages are of this form (there are lots of them..);- [WARNING] Bundle com.vogella.tycho.plugin4:com.vogella.tycho.plugin4:bundle:0.0.1-SNAPSHOT : Invalid package name: 'org.bytedeco.opencv.macosx-x86_64.include.opencv4.opencv2.videostab' [WARNING] Bundle com.vogella.tycho.plugin4:com.vogella.tycho.plugin4:bundle:0.0.1-SNAPSHOT : Invalid package name: 'org.bytedeco.opencv.macosx-x86_64.include.opencv4.opencv2.xfeatures2d' [WARNING] Bundle com.vogella.tycho.plugin4:com.vogella.tycho.plugin4:bundle:0.0.1-SNAPSHOT : Invalid package name: 'org.bytedeco.opencv.macosx-x86_64.include.opencv4.opencv2.ximgproc' [WARNING] Bundle com.vogella.tycho.plugin4:com.vogella.tycho.plugin4:bundle:0.0.1-SNAPSHOT : Invalid package name: 'org.bytedeco.opencv.macosx-x86_64.include.opencv4.opencv2.xphoto' [WARNING] Bundle com.vogella.tycho.plugin4:com.vogella.tycho.plugin4:bundle:0.0.1-SNAPSHOT : Invalid package name: 'org.bytedeco.opencv.macosx-x86_64.lib.cmake.opencv4' [WARNING] Bundle com.vogella.tycho.plugin4:com.vogella.tycho.plugin4:bundle:0.0.1-SNAPSHOT : Invalid package name: 'org.bytedeco.opencv.macosx-x86_64.share.licenses.opencv4' [WARNING] Bundle com.vogella.tycho.plugin4:com.vogella.tycho.plugin4:bundle:0.0.1-SNAPSHOT : Invalid package name: 'org.bytedeco.opencv.macosx-x86_64.share.opencv4' [WARNING] Bundle com.vogella.tycho.plugin4:com.vogella.tycho.plugin4:bundle:0.0.1-SNAPSHOT : Invalid package name: 'org.bytedeco.opencv.windows-x86' [WARNING] Bundle com.vogella.tycho.plugin4:com.vogella.tycho.plugin4:bundle:0.0.1-SNAPSHOT : Invalid package name: 'org.bytedeco.opencv.windows-x86.include' [WARNING] Bundle com.vogella.tycho.plugin4:com.vogella.tycho.plugin4:bundle:0.0.1-SNAPSHOT : Invalid package name: 'org.bytedeco.opencv.windows-x86.include.opencv2' ... They seem to be for all the jar files with native code; dlls, C++ headers etc Please someone tell me what I am doing wrong? I am new to maven-bundle-plugin.. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@felix.apache.org[mailto:users-unsubscr...@felix.apache.org] For additional commands, e-mail: users-h...@felix.apache.org[mailto:users-h...@felix.apache.org] --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@felix.apache.org For additional commands, e-mail: users-h...@felix.apache.org