I have small Java desktop application without any GUI. I use Ant to dev, run, build and release it. I didn't create a jar file for it. I use a .sh file to launch/run it with the attached JRE in the release.
Now I added a simple JavaFX 2 GUI on top of it. I still can dev, run, build and release with Ant. There is no special target or addition in the Ant file for JavaFX. After release, I cannot run it with the existing .sh file any more. I got the following error:
Exception in thread "main" java.lang.NoClassDefFoundError: javafx/application/Application
If I change to launch another entry point without JavaFX involved in the .sh file, it works.
I am pretty sure if I use Swing it will work right way. Why JavaFX is special? Do I have to use Ant or javafxpackager to do special deploy? Any simple way to resolve this? it is a desktop application only.
I am using jdk/jre 1.7.0_51 and on linux.
I am new to JavaFX. don't know if it is worthy to learn it.