mirror of
https://github.com/godotengine/godot.git
synced 2025-01-22 10:32:54 -05:00
Add loongarch64 support
This commit is contained in:
parent
47bc374edf
commit
e0693f8ad8
8 changed files with 16 additions and 4 deletions
|
@ -248,6 +248,9 @@ String Engine::get_architecture_name() const {
|
|||
return "ppc";
|
||||
#endif
|
||||
|
||||
#elif defined(__loongarch64)
|
||||
return "loongarch64";
|
||||
|
||||
#elif defined(__wasm__)
|
||||
#if defined(__wasm64__)
|
||||
return "wasm64";
|
||||
|
|
|
@ -518,6 +518,10 @@ bool OS::has_feature(const String &p_feature) {
|
|||
if (p_feature == "wasm") {
|
||||
return true;
|
||||
}
|
||||
#elif defined(__loongarch64)
|
||||
if (p_feature == "loongarch64") {
|
||||
return true;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if defined(IOS_SIMULATOR)
|
||||
|
|
|
@ -235,6 +235,7 @@ EditorPropertyNameProcessor::EditorPropertyNameProcessor() {
|
|||
capitalize_string_remaps["linuxbsd"] = "Linux/*BSD";
|
||||
capitalize_string_remaps["lod"] = "LOD";
|
||||
capitalize_string_remaps["lods"] = "LODs";
|
||||
capitalize_string_remaps["loongarch64"] = "loongarch64";
|
||||
capitalize_string_remaps["lowpass"] = "Low-pass";
|
||||
capitalize_string_remaps["macos"] = "macOS";
|
||||
capitalize_string_remaps["mb"] = "(MB)"; // Unit.
|
||||
|
|
|
@ -73,6 +73,7 @@ void GDExtensionExportPlugin::_export_file(const String &p_path, const String &p
|
|||
all_archs.insert("ppc32");
|
||||
all_archs.insert("ppc64");
|
||||
all_archs.insert("wasm32");
|
||||
all_archs.insert("loongarch64");
|
||||
all_archs.insert("universal");
|
||||
|
||||
HashSet<String> archs;
|
||||
|
|
|
@ -73,7 +73,7 @@ def get_flags():
|
|||
|
||||
def configure(env: "SConsEnvironment"):
|
||||
# Validate arch.
|
||||
supported_arches = ["x86_32", "x86_64", "arm32", "arm64", "rv64", "ppc32", "ppc64"]
|
||||
supported_arches = ["x86_32", "x86_64", "arm32", "arm64", "rv64", "ppc32", "ppc64", "loongarch64"]
|
||||
validate_arch(env["arch"], get_name(), supported_arches)
|
||||
|
||||
## Build type
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<members>
|
||||
<member name="binary_format/architecture" type="String" setter="" getter="">
|
||||
Application executable architecture.
|
||||
Supported architectures: [code]x86_32[/code], [code]x86_64[/code], [code]arm64[/code], [code]arm32[/code], [code]rv64[/code], [code]ppc64[/code], and [code]ppc32[/code].
|
||||
Supported architectures: [code]x86_32[/code], [code]x86_64[/code], [code]arm64[/code], [code]arm32[/code], [code]rv64[/code], [code]ppc64[/code], [code]ppc32[/code], and [code]loongarch64[/code].
|
||||
Official export templates include [code]x86_32[/code] and [code]x86_64[/code] binaries only.
|
||||
</member>
|
||||
<member name="binary_format/embed_pck" type="bool" setter="" getter="">
|
||||
|
|
|
@ -180,7 +180,7 @@ bool EditorExportPlatformLinuxBSD::get_export_option_visibility(const EditorExpo
|
|||
void EditorExportPlatformLinuxBSD::get_export_options(List<ExportOption> *r_options) const {
|
||||
EditorExportPlatformPC::get_export_options(r_options);
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "binary_format/architecture", PROPERTY_HINT_ENUM, "x86_64,x86_32,arm64,arm32,rv64,ppc64,ppc32"), "x86_64"));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "binary_format/architecture", PROPERTY_HINT_ENUM, "x86_64,x86_32,arm64,arm32,rv64,ppc64,ppc32,loongarch64"), "x86_64"));
|
||||
|
||||
String run_script = "#!/usr/bin/env bash\n"
|
||||
"export DISPLAY=:0\n"
|
||||
|
@ -282,6 +282,8 @@ String EditorExportPlatformLinuxBSD::_get_exe_arch(const String &p_path) const {
|
|||
return "arm64";
|
||||
case 0x00f3:
|
||||
return "rv64";
|
||||
case 0x0102:
|
||||
return "loongarch64";
|
||||
default:
|
||||
return "unknown";
|
||||
}
|
||||
|
|
|
@ -16,7 +16,7 @@ compatibility_platform_aliases = {
|
|||
}
|
||||
|
||||
# CPU architecture options.
|
||||
architectures = ["x86_32", "x86_64", "arm32", "arm64", "rv64", "ppc32", "ppc64", "wasm32"]
|
||||
architectures = ["x86_32", "x86_64", "arm32", "arm64", "rv64", "ppc32", "ppc64", "wasm32", "loongarch64"]
|
||||
architecture_aliases = {
|
||||
"x86": "x86_32",
|
||||
"x64": "x86_64",
|
||||
|
@ -31,6 +31,7 @@ architecture_aliases = {
|
|||
"ppcle": "ppc32",
|
||||
"ppc": "ppc32",
|
||||
"ppc64le": "ppc64",
|
||||
"loong64": "loongarch64",
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue