diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2022-12-14 16:13:38 +0100 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2022-12-14 16:42:14 +0100 |
commit | de5aaf1d13772e2859104ac0a03c0a0351859417 (patch) | |
tree | a3dd96c854a48fad23e00a0c88e78b24f494cdf0 | |
parent | eba33c67b49905973ee7c81a709046415a41e205 (diff) |
CI: Fix dumping GDExtension interface and API for godot-cpp
Follow-up to https://github.com/godotengine/godot-cpp/pull/960.
Fix exit code for --dump-extension-api and --dump-gdextension-interface.
Removed the planned API validation step as we still didn't implement
anything, and maintaining a stub isn't useful.
-rw-r--r-- | .github/workflows/linux_builds.yml | 17 | ||||
-rw-r--r-- | main/main.cpp | 1 | ||||
-rwxr-xr-x | misc/scripts/compare_extension_api.py | 11 |
3 files changed, 6 insertions, 23 deletions
diff --git a/.github/workflows/linux_builds.yml b/.github/workflows/linux_builds.yml index 9ec6c4a4e9..84fdb2180b 100644 --- a/.github/workflows/linux_builds.yml +++ b/.github/workflows/linux_builds.yml @@ -198,20 +198,13 @@ jobs: submodules: 'recursive' path: 'godot-cpp' - # Check extension API - - name: Check for extension api updates + # Dump GDExtension interface and API + - name: Dump GDExtension interface and API for godot-cpp build if: ${{ matrix.godot-cpp-test }} run: | - echo "Running --dump-extension-api to create extensions api." - VK_ICD_FILENAMES=$(pwd)/vk_swiftshader_icd.json DRI_PRIME=0 xvfb-run ${{ matrix.bin }} --audio-driver Dummy --dump-extension-api 2>&1 > /dev/null || true - misc/scripts/compare_extension_api.py godot-cpp/godot-headers/extension_api.json extension_api.json - - # Copy new extension API files into place - - name: Copy new extension API files into place - if: ${{ matrix.godot-cpp-test }} - run: | - cp -f extension_api.json godot-cpp/godot-headers/ - cp -f core/extension/gdextension_interface.h godot-cpp/godot-headers/godot/ + ${{ matrix.bin }} --headless --dump-gdextension-interface --dump-extension-api + cp -f gdextension_interface.h godot-cpp/gdextension/ + cp -f extension_api.json godot-cpp/gdextension/ # Build godot-cpp test extension - name: Build godot-cpp test extension diff --git a/main/main.cpp b/main/main.cpp index 8fa0a78480..1a005583af 100644 --- a/main/main.cpp +++ b/main/main.cpp @@ -2594,6 +2594,7 @@ bool Main::start() { } if (dump_gdextension_interface || dump_extension_api) { + OS::get_singleton()->set_exit_code(EXIT_SUCCESS); return false; } diff --git a/misc/scripts/compare_extension_api.py b/misc/scripts/compare_extension_api.py deleted file mode 100755 index f96db4278c..0000000000 --- a/misc/scripts/compare_extension_api.py +++ /dev/null @@ -1,11 +0,0 @@ -#!/usr/bin/env python -# -*- coding: utf-8 -*- - -import sys - -# TODO: -# Add a process that compares the original godot-cpp/godot-headers/extension_api.json with the new extension_api.json (both passed as arguments) and reports any API calls that have been removed. -# If we only have additions or no changes to the file, we pass -# For now we deem this too early because the API isn't stable enough yet. - -sys.exit(0) |