I'm trying to export my JavaFX 2 application using IntelliJ 13.1.2 on Windows 8 x64. This is my setup:
But when I build the artifact I get an error, this is the log:
Information:Compilation completed with 1 error and 0 warnings in 7 sec
Information:1 error
Information:0 warnings
Error:Java FX Packager: D:\Dropbox\Development\MultiWork-PC\out\artifacts\MultiWork_PC (Access is denied)
I don't know if it is a bug or more probably some problem with Windows permission. All the files are copied in the Artifact output folder:
Except the app itself! What I have tried:
NOTE: this doesn't happen if I deploy a jar instead of a JavaFX Application
I ended up using Maven to export my JavaFX app:
<plugin>
<groupId>com.zenjava</groupId>
<artifactId>javafx-maven-plugin</artifactId>
<version>8.1.1</version>
<configuration>
<mainClass>foo.bar.mainclass</mainClass>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.5.1</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
</plugins>
To clean and build run:
clean jfx:jar
In your /target/jfx/app
you will find your executable JavaFX jar file with a lib
folder containing all the dependencies.