Reputation: 633
Im using OpenJDK9 and created a parent child structure to deploy the app using JLink and JMod.
I follow the jigsaw example on Internet to create my structure of App. Before I was getting path must be directory when using JMod 3.0.0-alpha-1, then i find its a bug in Plugin, 3.0.0-alpha-2-SNAPSHOT was not available yet so i build it, the path errors gone but I'm getting new error.
These error cause by the dependencies i have added in POM file, If i comment the dependencies the project build successfully, but i want to build the project with these dependencies.
Caused by: java.util.zip.ZipException: duplicate entry: classes/META-INF/MANIFEST.MF
I have uploaded the project on git also Sample Project on GitHub
Upvotes: 6
Views: 2507
Reputation: 22746
You get this error because you have one or more similar classes on your classpath. These classes come from dependencies defined in the pom.xml
file.
Suggested solution:
First, use this plugin to check duplications in your classpath.
Then remove unnecessary dependencies from your pom.xml
OR exclude classes or jar files. This documentation can help you.
Hope that this will help you.
Upvotes: 0
Reputation: 33
This is caused because one or more of your dependency have ZipException class. it a conflict in class import. You should try removing all the imports and adding it one by one.
Upvotes: 0