My Dependencie is built as a nar
(which contains java files and a jni wrapper)
<dependency>
<groupId>jni</groupId>
<artifactId>jni</artifactId>
<version>1.0.0-SNAPSHOT</version>
</dependency>
now If I do
mvn clean package
it says Could not resolve dependencies for project java:javatest:jar:1.0.0-SNAPSHOT: Could not find artifact jni:jni:jar:1.0.0-SNAPSHOT
the problem is, that in a project with nar-Packaging the output is named .nar
instead of .jar
so if I copy the jni.nar
in my local repository(~/.m2/repository/jni/jni
) and name it jni.jar
it works fine.
Any Idea how I could solve that without manually renaming the file?
You probably need to tell Maven your dependency type is different:
NOTE: I'm guessing the type is "nar" here. Check the POM of the dependency to see what the actual type is.