-
-
Notifications
You must be signed in to change notification settings - Fork 701
Add api_version build option to select the API JSON file
#1897
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
cc23464 to
8375226
Compare
7df6252 to
9f0acbf
Compare
|
I've updated the CI so that it'll build for each supported API version (only 4.5 and 4.6 in this PR - more are added in the follow-up PRs), and then run the tests using each supported version of Godot. So, if it builds for 4.6, it just tests that against This is all I plan to add to this PR, however, it'll remain marked as DRAFT because the PR it depends on still isn't merged. |
9f0acbf to
799e4aa
Compare
|
Turns out I had one more thing to add: cmake support! Seems to work in my testing, but I really don't know what I'm doing with cmake :-) cc @enetheru |
Looks good to me. None of the changes to CMake add additional complexity, nothing raises my eyebrows. :) |
api_version build option to select the API JSON fileapi_version build option to select the API JSON file
799e4aa to
91480bf
Compare
|
Rebased and taken out of DRAFT now that #1895 is merged |
Ivorforce
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
| rm -rf ./project/.godot | ||
| export GODOT="${GODOT_BUILDS}/godot-${version}" | ||
| $GODOT --headless --version | ||
| # Need to run the editor so .godot is generated... but it crashes! Ignore that :-) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is that expected? Otherwise a TODO might be good
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was expected - at one time Godot's first time import of the test project was crashing. I'm not sure if that's the case anymore (or which version it crashed with), but since we're going to be running this with older versions of Godot (not just the latest) we may need it. I think we should keep it for now, since we're not even entirely sure how far back we're going with Godot versions
91480bf to
4b08f00
Compare
4b08f00 to
2f1695a
Compare
This builds on top of #1895, and is a replacement for our usual update of the
extension_api.jsonfile for Godot 4.6 (which we usually start doing at -beta1, so this also adds theextension_api.jsonfile for 4.6-beta1)The idea, is that we'll include
extension_api.jsonfiles for all the Godot versions that godot-cpp v10 is compatible with, and developers can specifyscons api_version=4.5(for example) to select an earlier API version. This is something that other GDExtension bindings do as well, for example, the Rust bindings.This is marked as a DRAFT because it depends on #1895 (the first godot-cpp v10 PR) which allows godot-cpp to be compatible with either Godot 4.5 or 4.6