joshua
joshua

Reputation: 11

How manage dependencies between jar files?

I have to compile a list of file .java for create 2 file jar and use this files as client and library.

Runining theme in this way

java -cp lib.jar:client.jar MainClass

although i succeded in creating lib.jar, compiling the file for client requires a file that is in lib.jar. The question is, how can i create a jar file that requires one or more other jar files?

Upvotes: 1

Views: 170

Answers (1)

Jigar Joshi
Jigar Joshi

Reputation: 240956

Generally you can use build tools like maven/ant with dependency manager like (maven & ivy, gradle, grape) to do this for you

Upvotes: 3

Related Questions