godot-kotlin-jvm icon indicating copy to clipboard operation
godot-kotlin-jvm copied to clipboard

Fix reflection usage in exported projects

Open chippmann opened this issue 1 year ago • 2 comments

Fixes #571

Note: this is intended as a quick fix for #571 so we can publish a hotfix. We still need to further investigate if a separate bootstrap jar for exported projects is still a good idea and still needed or if we should just export the bootstrap jar we ship with the editor.

@piiertho the graalvm config for the newly added tests are missing here. As i cannot remember how to check which configs are missing, could you give me a quick heads up again on discord?

This was tested on linux x64 on editor builds, debug and release exports.

Marked as draft until missing graalvm configs are added.

chippmann avatar Feb 07 '24 06:02 chippmann

@MartinHaeusler I'd appreciate if you could test this with your project as well if possible and you have the time.

chippmann avatar Feb 07 '24 06:02 chippmann

@chippmann I've just tested it locally; I checked out this PR from github, built the godot plugin, published to maven local, loaded it from there in my project, and did a clean build of my project. The godot-bootstrap.jar which was created this way now contains the full kotlin/reflect/jvm and kotlin/reflect/full packages. I then used the godot editor to export the project and started the standalone executable; everything worked like a charm!

Thank you very much for your efforts :)

MartinHaeusler avatar Feb 07 '24 21:02 MartinHaeusler