Java app uses own launcher and bundles JDK but OS X still insists that Java SE 6 be installed
Davin McCall
davmac at davmac.org
Thu May 16 08:36:41 PDT 2013
Hi,
I am responsible for a Java application which is deployed on multiple
platforms including OS X. With recent versions of the application we
distribute two separate bundles for OS X - one which uses the
JavaApplicationStub provided by Apple, and another one which includes a
bundled JDK 7 and uses a launcher produced in-house (a modification of
Oracle's JavaAppLauncher).
The issue is, with the latter bundle, Mac OS X still insists on you
having Java 6 installed if you try to run the application. Specifically
the message says:
"To open (application), you need a Java SE 6 runtime. Would you like to
install one now?"
If you don't install Java SE 6, you are unable to run the application,
despite the fact that JDK 7 is bundled (and, if you do install Java 6,
it nevertheless runs with the bundled Java 7).
What I'm struggling to figure out is how OS X decides that the
application requires Java? I've tried renaming the 'Java' dictionary in
the Info.plist file, and renaming the Java subfolder within the
Resources folder, without success. Does anyone have any ideas? Surely
it's possible to have an application with a bundled JDK run without
requiring a system JDK to be installed?
I've also asked this on StackOverflow:
http://stackoverflow.com/questions/16591780/how-does-mac-os-x-determine-that-an-application-needs-java
Thanks to anyone who can insist,
Davin
More information about the macosx-port-dev
mailing list