Skip to content

How to install OpenJFX for Debian and Others

License

Notifications You must be signed in to change notification settings

Devorlon/OpenJFX-Installation-Linux

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 

Repository files navigation

How to install Java 12 & JavaFX for Debian – Eclipse-IDE

  1. Install your OS of choice (Preferably Debian based)
  2. Update the system
  3. Run:
sudo apt-get install openjdk-12-jdk
  1. Run:
sudo snap install eclipse --classic
  1. Download OpenJFX 12
  2. Extract the .zip and place the contents in a folder called .javafx in your home folder.
  3. Open eclipse
  4. Select:
Eclipse -> Window -> Preferences -> Java -> Build Path -> User Libraries -> New
  1. Name it JavaFX12
  2. Click ‘Add External JARs…”
  3. Go to /home/.javafx/lib
  4. Select OK
  5. Select ‘Apply and Close’
  6. Select:
Eclipse -> Help -> Eclipse Marketplace
  1. In the find field search for ‘FX’ (press enter)
  2. Install a version greater than or equal to ‘e(fx)clispe 3.5.0’
  3. Accept License agreement and Certificates then restart.

Well done you can now create Java and JavaFX applications in Linux.

Help:

Q: Will this work on any Distro or even Windows?

A: Yes, it should as long as you replace the ‘apt install’ with your system counterpart.

Q: When I try to run my application, it tells me:

Error: JavaFX runtime components are missing, and are required to run this application.

A: Follow these steps:

  1. Select: Eclipse -> Run -> Run Configurations
  2. Under ‘Java Application’ select your created program
  3. Under the arguments tab insert the following command into ‘VM arguments’ as one line:
-module-path /home/YOUR_USERNAME/.javafx/lib -add-modules javafx.controls,javafx.graphics,javafx.fxml
  1. Select ‘Apply’

Q: Will this work for Netbeans / IntelliJ?

A: No, a lot of this is specific to Eclipse if you want a good guide follow the OpenJFX documentation: https://openjfx.io/openjfx-docs/#introduction

Q: Can you add pictures?

A: I would like to as I find them easy to follow as well, but I can’t be bothered.

Q: Can I contrubute?

A: Just make a Pull Request and I'll probably merge it.

Q: My machine is now broken.

A: That’s not a question, and I don’t care reset your machine and try again.

Q: You stole this from openjfx.io.

A: Yes, yes I did. Though I did it because I / the people I wrote this for found it easier to follow. (P.S. Please go check these guys out they’ve done tones for the FX community)

About

How to install OpenJFX for Debian and Others

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published