Thread: how specific class into jar
hello,
i'm losing lot of time success little , basic problem.
context:
developing application using specific .jar path/jdk/lib
classpath not fixed..
i've seen -classpath option incompatible -jar option (i.e. manifest..)
solution not abble success it..
want access main.class , add path/jdk/lib in -classpath , not use -jar option.
in practice, :
java -cp ./lib:/path/to/jdk/lib/tools.jar my.main.class
suppose in directory .jar , lib directory.
: java.lang.noclassdeffounderror: my.main.class
miss ?
can more specific , give exact filenames , pathnames using , working in anf actual comman line.
1 thing may effecting you don't put .class extension of main class in java line.
also directory of class file must match class path, given ./lib in classpath, main class file should ./lib/my/main.classcode:java -cp ./lib:/path/to/jdk/lib/tools.jar my.main
Forum The Ubuntu Forum Community Ubuntu Specialised Support Development & Programming Programming Talk how specific class into jar
Ubuntu
Comments
Post a Comment