mirror of
https://github.com/godotengine/godot.git
synced 2026-01-06 10:11:57 +03:00
Merge pull request #110263 from raulsntos/dotnet/android-net9.0
[.NET] Require `net9.0` for Android exports
This commit is contained in:
@@ -26,6 +26,10 @@ namespace GodotTools.ProjectEditor
|
|||||||
var mainGroup = root.AddPropertyGroup();
|
var mainGroup = root.AddPropertyGroup();
|
||||||
mainGroup.AddProperty("TargetFramework", GodotMinimumRequiredTfm);
|
mainGroup.AddProperty("TargetFramework", GodotMinimumRequiredTfm);
|
||||||
|
|
||||||
|
// Non-gradle builds require .NET 9 to match the jar libraries included in the export template.
|
||||||
|
var net9 = mainGroup.AddProperty("TargetFramework", "net9.0");
|
||||||
|
net9.Condition = " '$(GodotTargetPlatform)' == 'android' ";
|
||||||
|
|
||||||
mainGroup.AddProperty("EnableDynamicLoading", "true");
|
mainGroup.AddProperty("EnableDynamicLoading", "true");
|
||||||
|
|
||||||
string sanitizedName = IdentifierUtils.SanitizeQualifiedIdentifier(name, allowEmptyIdentifiers: true);
|
string sanitizedName = IdentifierUtils.SanitizeQualifiedIdentifier(name, allowEmptyIdentifiers: true);
|
||||||
|
|||||||
Binary file not shown.
1
modules/mono/thirdparty/libSystem.Security.Cryptography.Native.Android.jar.source.txt
vendored
Normal file
1
modules/mono/thirdparty/libSystem.Security.Cryptography.Native.Android.jar.source.txt
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
https://www.nuget.org/packages/Microsoft.NETCore.App.Runtime.Mono.android-arm64/9.0.4
|
||||||
@@ -2739,6 +2739,7 @@ bool _validate_dotnet_tfm(const String &required_tfm, String &r_error) {
|
|||||||
List<String> args;
|
List<String> args;
|
||||||
args.push_back("build");
|
args.push_back("build");
|
||||||
args.push_back(project_path);
|
args.push_back(project_path);
|
||||||
|
args.push_back("/p:GodotTargetPlatform=android");
|
||||||
args.push_back("--getProperty:TargetFramework");
|
args.push_back("--getProperty:TargetFramework");
|
||||||
|
|
||||||
int exitcode;
|
int exitcode;
|
||||||
@@ -2778,9 +2779,9 @@ bool EditorExportPlatformAndroid::has_valid_export_configuration(const Ref<Edito
|
|||||||
err += TTR("Exporting to Android when using C#/.NET is experimental.") + "\n";
|
err += TTR("Exporting to Android when using C#/.NET is experimental.") + "\n";
|
||||||
|
|
||||||
if (!gradle_build_enabled) {
|
if (!gradle_build_enabled) {
|
||||||
// For template exports we only support .NET 8 because the template
|
// For template exports we only support .NET 9 because the template
|
||||||
// includes .jar dependencies that may only be compatible with .NET 8.
|
// includes .jar dependencies that may only be compatible with .NET 9.
|
||||||
if (!_validate_dotnet_tfm("net8.0", err)) {
|
if (!_validate_dotnet_tfm("net9.0", err)) {
|
||||||
r_error = err;
|
r_error = err;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user