2shady4u / godot-sqlite

GDExtension wrapper for SQLite (Godot 4.x+)
MIT License
947 stars 82 forks source link

[godot4, linux] add debug build to github actions for gd-extension branch #95

Closed Dfred closed 1 year ago

Dfred commented 2 years ago

Is your feature request related to a problem? Please describe.

  1. README.md of the master branch has a convenient link to the gd-extension branch for Godot4 projects, but the branch's README.md How to install? part is mostly obsolete information for the gd-extension branch. I suggest removing it and replacing it with a link to #71 for now.

  2. After following instructions found in that issue only addons/godot-sqlite/bin/libgdsqlite.linux.release.x86_64.so exists, Godot4 editor fails to load the extension: it tries loading the debug version of the lib, yet Actions currently in place only build the release version.

ERROR: Can't open dynamic library: /home/user/Godot/godot-sqlite/demo/addons/godot-sqlite/bin/libgdsqlite.linux.debug.x86_64.so. Error: /home/user/opt/../lib/libgdsqlite.linux.debug.x86_64.so: cannot open shared object file: No such file or directory at: open_dynamic_library (drivers/unix/os_unix.cpp:453)

ERROR: GDExtension dynamic library not found: /home/user/Godot/godot-sqlite/demo/addons/godot-sqlite/bin/libgdsqlite.linux.debug.x86_64.so at: open_library (core/extension/native_extension.cpp:268)

ERROR: Failed loading resource: res://addons/godot-sqlite/gdsqlite.gdextension. Make sure resources have been imported by opening the project in the editor at least once. at: _load (core/io/resource_loader.cpp:221)

Describe the solution you'd like

Please include debug version in Actions, or simply mention the need for compiling the debug version in README.md

Describe alternatives you've considered

I tried removing the line linux.debug.x86_64 = "res://addons/godot-sqlite/bin/libgdsqlite.linux.debug.x86_64.so" in addons/godot-sqlite/gdsqlite.gdextension

Additional context

Ubuntu 22.04.1 LTS

2shady4u commented 2 years ago

Hi @Dfred,

This is planned to be implemented at some point! :slightly_smiling_face:

Dfred commented 1 year ago

FYI, I've done it in my fork

2shady4u commented 1 year ago

This has now finally been implemented 🥳

@Dfred I checked out how you did it in your fork, but I decided against duplicating the build.yml and decided to make use of a workflow matrix instead.

Dfred commented 1 year ago

@2shady4u thanks for implementing the better approach!