I have made a javafx application. For OCR purpose I have used JNA. When I am trying to generate the .dmg or .exe file then the build goes successful but it doesn't generate the .dmg or .exe because of the below error:
The jar libs/jna.jar has a main class com.sun.jna.Native that does not match the declared main xx.xxxxx.xxx.MainAppClass
The jar libs/jna.jar has a main class com.sun.jna.Native that does not match the declared main xx.xxxx.xxx.MainAppClass
Bundler DMG Installer skipped because of a configuration problem: Main application jar is missing.
Advice to fix: Make sure to use fx:jar task to create main application jar.
BUILD SUCCESSFUL
How can I fix it?