0

I followed all the instructions in Gluon Docs, and when I compile I get a weird

[Thu Dec 03 13:16:47 IST 2020][INFO] [SUB] Fatal error:java.lang.NoClassDefFoundError: javafx/application/Application

How do I fix this?

I am using the latest GraalVM build, latest gluon client plugin.

Entire output + log

rnayabed
  • 113
  • 10
  • Based on your logs, can you check the contents of the jar created under the temp folder, `C:\Users\DEBAYA~1\AppData\Local\Temp\classes1516106915740802479\classes.jar` ? See if it has the JavaFX jars, or post its manifest here? – José Pereda Dec 03 '20 at 08:54
  • @JoséPereda I checked the jar and it contains only classes of my project. No dependencies or javafx jars included. the MANIFEST.MF file just has ``` Manifest-Version: 1.0 Created-By: 11.0.8 (GraalVM Community) ``` – rnayabed Dec 03 '20 at 08:59
  • Sorry, my bad, this is the jar you have to check: `C:\Users\DEBAYA~1\AppData\Local\Temp\classpathJar11912885979961198418.jar` – José Pereda Dec 03 '20 at 09:00
  • @JoséPereda https://gist.github.com/dubbadhar/90acceac768b78c36d684b9790ef797a – rnayabed Dec 03 '20 at 09:07
  • 1
    Seems you are running into this [issue](https://github.com/gluonhq/substrate/issues/813), and the jars in your ~/.gluon path are missed. – José Pereda Dec 03 '20 at 09:09
  • Is there a way to change the location of the `.gluon` folder and put it away into another location? I think my name `Debayan Sutradhar` is causing issues in the path. – rnayabed Dec 03 '20 at 09:10
  • Gluon Substrate [uses](https://github.com/gluonhq/substrate/blob/master/src/main/java/com/gluonhq/substrate/Constants.java#L35) `user.home` for that. This is how you might override it: https://stackoverflow.com/a/1501261/3956070 – José Pereda Dec 03 '20 at 09:17
  • @JoséPereda nevermind, I renamed my user name, but now I am getting even more cryptic [errors](https://gist.github.com/dubbadhar/ff029f4bf3a3d451c2fb8a31439feed6). I researched a bit and found [this](https://github.com/oracle/graal/issues/2420) – rnayabed Dec 03 '20 at 09:34
  • You are running now into "regular" errors when building native image. So this is for another question. – José Pereda Dec 03 '20 at 09:37
  • @JoséPereda here https://stackoverflow.com/questions/65123483/unsupported-method-error-gluon-client-for-windows – rnayabed Dec 03 '20 at 09:48

0 Answers0