Enable mono editor build in CI

This commit is contained in:
qarmin 2021-10-01 08:14:54 +02:00
parent 38c698c485
commit 071829acc5
5 changed files with 34 additions and 33 deletions

View File

@ -18,13 +18,15 @@ jobs:
fail-fast: false
matrix:
include:
- name: Editor (target=release_debug, tools=yes, tests=yes)
cache-name: linux-editor
- name: Editor w/ Mono (target=release_debug, tools=yes, tests=yes)
cache-name: linux-editor-mono
target: release_debug
tools: true
tests: true
tests: false # Disabled due freeze caused by mix Mono build and CI
sconsflags: module_mono_enabled=yes mono_glue=no
doc-test: true
bin: "./bin/godot.linuxbsd.opt.tools.64"
bin: "./bin/godot.linuxbsd.opt.tools.64.mono"
build-mono: true
artifact: true
- name: Editor and sanitizers (target=debug, tools=yes, tests=yes, use_asan=yes, use_ubsan=yes)
@ -36,6 +38,7 @@ jobs:
proj-test: true
godot-cpp-test: true
bin: "./bin/godot.linuxbsd.tools.64s"
build-mono: false
# Skip 2GiB artifact speeding up action.
artifact: false
@ -45,6 +48,7 @@ jobs:
tools: false
tests: false
sconsflags: module_mono_enabled=yes mono_glue=no debug_symbols=no
build-mono: false
artifact: true
steps:
@ -80,11 +84,26 @@ jobs:
tools: ${{ matrix.tools }}
tests: ${{ matrix.tests }}
- name: Generate Mono glue
if: ${{ matrix.build-mono }}
run: |
${{ matrix.bin }} --headless --generate-mono-glue modules/mono/glue || true
# Rebuild with mono
- name: Compilation (mono_glue=yes)
uses: ./.github/actions/godot-build
if: ${{ matrix.build-mono }}
with:
sconsflags: ${{ env.SCONSFLAGS }} ${{ matrix.sconsflags }} mono_glue=yes
platform: linuxbsd
target: ${{ matrix.target }}
tools: ${{ matrix.tools }}
# Execute unit tests for the editor
- name: Unit tests
if: ${{ matrix.tests }}
run: |
${{ matrix.bin }} --test
${{ matrix.bin }} --test --headless
# Check class reference
- name: Check for class reference updates

View File

@ -1315,8 +1315,6 @@
</member>
<member name="mono/profiler/enabled" type="bool" setter="" getter="" default="false">
</member>
<member name="mono/project/auto_update_project" type="bool" setter="" getter="" default="true">
</member>
<member name="mono/unhandled_exception_policy" type="int" setter="" getter="" default="0">
</member>
<member name="navigation/2d/default_cell_size" type="int" setter="" getter="" default="10">

View File

@ -2051,8 +2051,6 @@ bool Main::start() {
GLOBAL_DEF("mono/profiler/args", "log:calls,alloc,sample,output=output.mlpd");
GLOBAL_DEF("mono/profiler/enabled", false);
GLOBAL_DEF("mono/unhandled_exception_policy", 0);
// From editor/csharp_project.cpp.
GLOBAL_DEF("mono/project/auto_update_project", true);
#endif
DocTools doc;

View File

@ -12,13 +12,10 @@
</tutorials>
<methods>
<method name="new" qualifiers="vararg">
<return type="Variant">
</return>
<return type="Variant" />
<description>
Returns a new instance of the script.
</description>
</method>
</methods>
<constants>
</constants>
</class>

View File

@ -11,66 +11,55 @@
</tutorials>
<methods>
<method name="attach_thread">
<return type="void">
</return>
<return type="void" />
<description>
Attaches the current thread to the Mono runtime.
</description>
</method>
<method name="detach_thread">
<return type="void">
</return>
<return type="void" />
<description>
Detaches the current thread from the Mono runtime.
</description>
</method>
<method name="get_domain_id">
<return type="int">
</return>
<return type="int" />
<description>
Returns the current MonoDomain ID.
[b]Note:[/b] The Mono runtime must be initialized for this method to work (use [method is_runtime_initialized] to check). If the Mono runtime isn't initialized at the time this method is called, the engine will crash.
</description>
</method>
<method name="get_scripts_domain_id">
<return type="int">
</return>
<return type="int" />
<description>
Returns the scripts MonoDomain's ID. This will be the same MonoDomain ID as [method get_domain_id], unless the scripts domain isn't loaded.
[b]Note:[/b] The Mono runtime must be initialized for this method to work (use [method is_runtime_initialized] to check). If the Mono runtime isn't initialized at the time this method is called, the engine will crash.
</description>
</method>
<method name="is_domain_finalizing_for_unload">
<return type="bool">
</return>
<argument index="0" name="domain_id" type="int">
</argument>
<return type="bool" />
<argument index="0" name="domain_id" type="int" />
<description>
Returns [code]true[/code] if the domain is being finalized, [code]false[/code] otherwise.
</description>
</method>
<method name="is_runtime_initialized">
<return type="bool">
</return>
<return type="bool" />
<description>
Returns [code]true[/code] if the Mono runtime is initialized, [code]false[/code] otherwise.
</description>
</method>
<method name="is_runtime_shutting_down">
<return type="bool">
</return>
<return type="bool" />
<description>
Returns [code]true[/code] if the Mono runtime is shutting down, [code]false[/code] otherwise.
</description>
</method>
<method name="is_scripts_domain_loaded">
<return type="bool">
</return>
<return type="bool" />
<description>
Returns [code]true[/code] if the scripts domain is loaded, [code]false[/code] otherwise.
</description>
</method>
</methods>
<constants>
</constants>
</class>