Reputation: 10354
I have a class file Main.class
which needs a JAR file abc.jar
to run.
Both files are in the same directory. Now I try to run the class file with
java -cp "." Main
but I get a java.lang/NoClassDefFoundError
.
I thought -cp "."
tells the classpath to include the current directory, but somehow it doesn't.
How do I get this JAR file in the current directory on the class path?
Upvotes: 0
Views: 400