Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows binaries don't include MS Visual Studio 2017 redistributables needed for OpenJFX #116

Closed
lhochet opened this issue Apr 22, 2019 · 8 comments
Assignees
Labels
bug Something isn't working windows Windows-related issue
Milestone

Comments

@lhochet
Copy link

lhochet commented Apr 22, 2019

On Windows (tried on a clean Windows 7 and Windows 10 1809),
a JavaFX application fails to start with this error:
C:\dev>java -cp cls test.JavaFXApplication1
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
at com.sun.javafx.tk.quantum.QuantumRenderer.getInstance(QuantumRenderer.java:280)
at com.sun.javafx.tk.quantum.QuantumToolkit.init(QuantumToolkit.java:221)
at com.sun.javafx.tk.Toolkit.getToolkit(Toolkit.java:248)
at com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:209)
at com.sun.javafx.application.LauncherImpl.startToolkit(LauncherImpl.java:675)
at com.sun.javafx.application.LauncherImpl.launchApplicationWithArgs(LauncherImpl.java:337)
at com.sun.javafx.application.LauncherImpl.launchApplication(LauncherImpl.java:328)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at sun.launcher.LauncherHelper$FXHelper.main(LauncherHelper.java:767)
Caused by: java.lang.RuntimeException: Error initializing QuantumRenderer: no suitable pipeline found
at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.init(QuantumRenderer.java:94)
at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.run(QuantumRenderer.java:124)
at java.lang.Thread.run(Thread.java:748)
Exception in thread "main" java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at sun.launcher.LauncherHelper$FXHelper.main(LauncherHelper.java:767)
Caused by: java.lang.RuntimeException: No toolkit found
at com.sun.javafx.tk.Toolkit.getToolkit(Toolkit.java:260)
at com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:209)
at com.sun.javafx.application.LauncherImpl.startToolkit(LauncherImpl.java:675)
at com.sun.javafx.application.LauncherImpl.launchApplicationWithArgs(LauncherImpl.java:337)
at com.sun.javafx.application.LauncherImpl.launchApplication(LauncherImpl.java:328)
... 5 more

The test program is
JavaFXApplication1.java

The source code for Toolkit suggests the MS Visual Studio 2017 redistributables are missing,

Adding them from Visual Studio or installing them specifically fixes the issue.

@navyxliu
Copy link
Contributor

@lhochet Thanks for bringing this up. We'll verify this and update the issue when we have more information on a fix.

@ziyiluo ziyiluo added the windows Windows-related issue label Apr 22, 2019
@EricEdens
Copy link
Contributor

Interesting, so, I was able to run your program successfully on a Windows 10 Pro system. The system had VS 2019 installed, however. After uninstalling it, the program still ran.

We're setting up a new instance of Windows Server 2008 that never had Visual Studio installed to try it there.

@lhochet, can you paste a link to where you downloaded Corretto? Also, what version are you using?

  • Platform: 64-bit or 32-bit
  • Bundling: JDK or JRE
  • Output of java -version

@jguo11
Copy link
Contributor

jguo11 commented Apr 22, 2019

The issue has been tested at Windows_Server-2008-R2_SP1-English-64Bit AMI with the following setup:

  • Without Visual Studio installed: reproducible
  • With Visual Studio 2010 Express (with module Desktop development with C++ and Universal Windows Platform development): reproducible
  • With Visual Studio 2017 (with module Desktop development with C++ and Universal Windows Platform development): passed

@lhochet
Copy link
Author

lhochet commented Apr 23, 2019

Apologies
I used the versions downloaded at https://docs.aws.amazon.com/corretto/latest/corretto-8-ug/downloads-list.html
I've used amazon-corretto-8.212.04.2-windows-x86.msi with a clean (only an up to date) Windows 7 VM (I checked the image of amazon-corretto-8.212.04.2-windows-x86-jre.zip and saw that it was similar to the embedded JRE in the JDK)
I've used amazon-corretto-8.212.04.2-windows-x64.msi with a clean Windows 10 1809.
For this later setup, java -version outputs:
openjdk version "1.8.0_212"
OpenJDK Runtime Environment Corretto-8.212.04.2 (build 1.8.0_212-b04)
OpenJDK 64-Bit Server VM Corretto-8.212.04.2 (build 25.212-b04, mixed mode)

@sparc78
Copy link

sparc78 commented Apr 29, 2019

I had the same issue on a clean Windows 7 up-to-date machine.

For information, everything was working with corretto8-u202.

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
	at com.sun.javafx.tk.quantum.QuantumRenderer.getInstance(QuantumRenderer.java:280)
	at com.sun.javafx.tk.quantum.QuantumToolkit.init(QuantumToolkit.java:221)
	at com.sun.javafx.tk.Toolkit.getToolkit(Toolkit.java:248)
	at com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:209)
	at com.sun.javafx.application.LauncherImpl.startToolkit(LauncherImpl.java:675)
	at com.sun.javafx.application.LauncherImpl.launchApplicationWithArgs(LauncherImpl.java:337)
	at com.sun.javafx.application.LauncherImpl.launchApplication(LauncherImpl.java:328)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at sun.launcher.LauncherHelper$FXHelper.main(LauncherHelper.java:767)
Caused by: java.lang.RuntimeException: Error initializing QuantumRenderer: no suitable pipeline found
	at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.init(QuantumRenderer.java:94)
	at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.run(QuantumRenderer.java:124)
	at java.lang.Thread.run(Thread.java:748)
Exception in thread "main" java.lang.reflect.InvocationTargetException
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at sun.launcher.LauncherHelper$FXHelper.main(LauncherHelper.java:767)
Caused by: java.lang.RuntimeException: No toolkit found
	at com.sun.javafx.tk.Toolkit.getToolkit(Toolkit.java:260)
	at com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:209)
	at com.sun.javafx.application.LauncherImpl.startToolkit(LauncherImpl.java:675)
	at com.sun.javafx.application.LauncherImpl.launchApplicationWithArgs(LauncherImpl.java:337)
	at com.sun.javafx.application.LauncherImpl.launchApplication(LauncherImpl.java:328)
	... 5 more

@davecurrie davecurrie added the bug Something isn't working label May 6, 2019
@davecurrie davecurrie added this to the 8u222 milestone May 6, 2019
@Loffe
Copy link

Loffe commented May 16, 2019

I also run into this issue. To run JavaFX applications with Corretto 8.212.04.2, the MSVC 2015 c++ runtime must be installed, otherwise the previously mentioned errors occurs.

As a reference ZuluFX includes the necessary DLL:s (including msvcp140.dll) in their distribution
(https://cdn.azul.com/zulu/bin/zulu8.38.0.13-ca-fx-jre8.0.212-win_x64.zip)

@lhochet
Copy link
Author

lhochet commented Jul 17, 2019

8u222 fixes it for me.
Thanks.

@TianminShi TianminShi self-assigned this Jul 17, 2019
@TianminShi
Copy link
Contributor

yes, this has been fixed in https://github.com/corretto/corretto-8/releases/tag/8.222.10.3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working windows Windows-related issue
Projects
None yet
Development

No branches or pull requests

9 participants