As a B2C Java developer, I have to say it: don't distribute jars to end users. The user experience is horrific. Knowing how to make executable jars is valuable, just make sure it is the step in your ant file right before you execute your native wrapping.<p>Java build tools are wonderfully cross platform so you can use the following pair regardless of your development environment, as far as I know. I routinely build BCC for Macs on Windows Vista.<p>Launch4j: packs jars into self-contained .exes, with all the trimmings. Includes ant integration. <a href="http://launch4j.sourceforge.net/" rel="nofollow">http://launch4j.sourceforge.net/</a><p>JarBundler: an Ant task which packs jars into Mac applications <a href="http://jarbundler.sourceforge.net/" rel="nofollow">http://jarbundler.sourceforge.net/</a><p>You need a file called JavaApplicationStub to get JarBundler to work. Macs can apparently produce it with software that comes onboard. I got mine by outsourcing wrapping of the very first Mac version of BCC to somebody on RentACoder, and since they I've just copy/pasted every time I've done a version upgrade. I really don't understand the internals of Java Mac applications, but I think you can also copy/paste any JavaApplicationStub you encounter on the Internet, if you're also developing on a non-Mac platform.<p>(Wrapping isn't quite the last thing you'll need to do to make a Java app cross-platform -- ask me some time about the joys of finding a good directory to store settings in -- but it is a low-effort absurdly-high-reward step to take.)<p>I don't have any experience with deploying B2C Java apps to Linux users so I don't know what I'd do for wrapping it there. (While I will probably never write B2C for Linux users, I would be interested if someone with experience with it shared what they did.)
Somebody might find this useful: <a href="http://github.com/burke/cljtemplate" rel="nofollow">http://github.com/burke/cljtemplate</a> -- a barebones template project for clojure, using ant, with compilation for java and clojure source.