Earlier, I had just one jar file and the manifest was set up such that I can simply run my program as:
java -jar MyApp.jar
java -cp "*" com.mycompany.mypackage.App
java -cp "*" -jar MyApp.jar
I have a Manifest.mf file like this.
Manifest-Version: 1.0 Main-Class: com.mycompany.mypackage.App Class-Path: MyApp.jar MyCore.jar log4j.jar
You can just add any jar files you need to the Class-Path line. Then as long as the jars are in the class path you can run the java -jar command without -cp.