Is there a way to configure OpenJFX 11 to extract their DLLs into a different user-specified directory?
While trying to migrate an existing Java 10/Maven project to Java 11, I tried using OpenJDK 11. To get the code build working, I needed to add the JavaFX JARs into the Maven pom.xml configuration files (because JavaFX is no longer a built-in part of Java 11).
However, at runtime I discovered errors due to OpenJFX extracting DLL files into a user directory and then having access failures (see errors, below). I've had many projects over the years that had errors when working with the C:\Users* directories (from Microsoft Windows interfering with file locks and directory permissions, anti-virus scans, etc), so I try to avoid those directories whenever possible. The Java project works properly under Java 10 on Windows 7 and on RedHat 7, which seems to imply that the Oracle's JavaFX 10 JARs are not extracting DLLs into the C:\Users* directories. OpenJFX seems to have no troubles writing the DLLs into those directories, but it cannot read those same files afterwards.
I am running on Microsoft Windows 7 Professional 64-bit with service-pack 1. I haven't tried running on Linux yet with OpenJDK 11 and OpenJFX, but I would imagine OpenJFX would try to extract its DLLs on that platform as well.
Example runtime Java errors caused by OpenJFX:
Loading library prism_d3d from resource failed: java.lang.UnsatisfiedLinkError: C:\Users\MyUserName\.openjfx\cache\11\prism_d3d.dll: Access is denied
java.lang.UnsatisfiedLinkError: C:\Users\MyUserName\.openjfx\cache\11\prism_d3d.dll: Access is denied
Loading library prism_sw from resource failed: java.lang.UnsatisfiedLinkError: C:\Users\MyUserName\.openjfx\cache\11\prism_sw.dll: Access is denied
java.lang.UnsatisfiedLinkError: C:\Users\MyUserName\.openjfx\cache\11\prism_sw.dll: Access is denied
Graphics Device initialization failed for : d3d, sw
Error initializing QuantumRenderer: no suitable pipeline found
java.lang.RuntimeException: java.lang.RuntimeException: Error initializing QuantumRenderer: no suitable pipeline found