How to make JNLP download the correct version of JavaFX 2?
32bit-64bit, cross-platform, java, javafx-2, jnlp
Solution
Jnlp and plugin modes are supported only on Windows in current JavaFX 2.1
Mac/Linux runtime is planned to be added in 2.2 release. You can try development preview bundles: http://www.oracle.com/technetwork/java/javafx/downloads/devpreview-1429449.html
Problem
JavaFX 2 is highly dependent on native code. For my desktop application, I would like to select the best-matching JavaFX flavor for each supported OS to make the installation on the target systems as painless as possible. Since JavaFX 2 comes with several Ant tasks to help with deployment, I thought this was the way to go, but I seem to have hit a dead end. The `deploy` task generates a JNLP file which includes a resource reference that calls the JavaFX installer: ``` <resources> <jfx:javafx-runtime version="2.1+" ref="http://javadl.sun.com/webapps/download/GetFile/javafx-latest/windows-i586/javafx2.jnlp"/> </resources> ``` This obviously won't work on OSs other than Windows, possibly even 32-bit Windows. According to the JNLP doc, OS-dependent resource selection is possible, though: ``` <resources os="SunOS" arch="sparc"> ... </resources> ``` However, I can't figure out the URLs for the different platforms. Are they documented somewhere? Is there another way to reach my goal? Please note that there already is a similar question, but it limits itself to the 32/64-bit part of the issue and goes unanswered at that.