Using Jlink to create custom runtime and it keeps failing #1425
Replies: 4 comments 1 reply
-
|
I create a demo project here: please fork it and run it locally here is what I got |
Beta Was this translation helpful? Give feedback.
-
|
It works fine when I use full JDK and JavaFX |
Beta Was this translation helpful? Give feedback.
-
|
I guess the problem is about the media try {
Media audio = new Media(getClass().getClassLoader().getResource("assets/music/maou_game_theme01.mp3").toExternalForm());
var mediaPlayer = new MediaPlayer(audio);
mediaPlayer.play();
}catch (Exception e){
e.printStackTrace();
}this code cause the crash new Media(getClass().getClassLoader().getResource("assets/music/maou_game_theme01.mp3").toExternalForm()); |
Beta Was this translation helpful? Give feedback.
-
|
Not sure whether it is related to this issue: |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi:
Not sure this is the bug of JavaFX or FXGL highly likely is JavaFX's bug
I tried to run the FXGL game in my IDE and it works fine
when releasing, I created a custom JRE using jlink
and when using the jlinked JRE to run the FXGL game
it failed
These code may cause the game/project to crash
keep telling me this information:
command:
bin/java -XX:+UseZGC --enable-native-access=javafx.graphics,javafx.media -m com.whitewoocity.fxglruntime/com.whitewoodcity.Mainand
seems like these two dylib has some problem:
[libsystem_platform.dylib+0x340c] _platform_memmove+0x1bc
j com.sun.media.jfxmedia.locator.Locator.setConnectionProperty(Ljava/lang/String;Ljava/lang/Object;)V+0 javafx.media@25-ea
any ideas why?
thx
Beta Was this translation helpful? Give feedback.
All reactions