I have downloaded a Linux executable for the program CircuitSim. You can see the downloads here:
https://www.roiatalla.com/public/CircuitSim/
I downloaded the version 1.6.2, hoping that I wouldn’t have problems with needing a newer version of Java.
My current version of Java is
$ java -version
openjdk version "11.0.23" 2024-04-16
OpenJDK Runtime Environment (build 11.0.23+9-post-Ubuntu-1ubuntu122.04.1)
OpenJDK 64-Bit Server VM (build 11.0.23+9-post-Ubuntu-1ubuntu122.04.1, mixed mode, sharing)
I’ve marked the downloaded executable as an executable program, and then in a terminal ran ./CircuitSim1.6.2
.
The response it gives is
Error: Could not find or load main class com.ra4king.circuitsim.gui.CircuitSim
Caused by: java.lang.NoClassDefFoundError: javafx/application/Application
I’m guessing this has something to do with this post: Caused by: java.lang.NoClassDefFoundError: javafx/application/Application
But I don’t understand pretty much anything that’s being said there, I’m not familiar with Java EE. But my guess is that the solutions there are relevant for when you’re calling on the Java compiler directly. Here, if I understand my situation a little, I’m calling an executable that’s calling the compiler — so I think I can’t use the solution there? I dunno.
Any help on how to run this program would be appreciated.
2
Answers
firstly,you can try again reload this jar,may you can maven clean let u know the local source not error; if error again after you done,try to read demo for javafx such as
https://gitee.com/westinyang/javafx-jdk11-start
, if always error again~ i guess maybe java compiler hadn’t choose the right classloader,u can try update your local jdk version,such as jdk 8;Root cause:
You have not installed and configured the JavaFX SDK.
The easiest way:
install a JDK that already integrates JavaFX.
Use SDKMAN to install a JDK with JavaFX.
You can use
sdk list java
and then look for files withxxx.fx.xxx
in the name to select an installation.After the installation is complete, execute the following instructions: