java - Build a runnable .jar or an exe with various resources - How? -


i need / advice. programmed little game, game has lot of resources , different libraries. libraries native libraries. maven (like slick2d used) , locally saved on drive because not access them via maven.

now i'd generate runnable .jar start little game, what's best way generate .jar various dependencies stated above? tried lot of stuff jarsplicer, mvn package , other stuff. googling lot , read write extractor archieven goal.

is neccessary? wanted feedback of ppl more experienced me regarding task. if need can surely provide more information project hierachy, used libraries etc.

so far ended getting jar ~20 mb big, incapable of starting, or maybe starting not running main method should be.

thanks advices / help!

i second @rahul's comment.

you can use maven assembly plugin:

... aggregate project output along dependencies, modules, site documentation, , other files single distributable archive.

re "incapable of starting" see <mainclass> on usage page, creating executable jar.


Comments