Merge pull request #29290 from ShyRed/godefquo
Escape quote char for non-Windows OS
This commit is contained in:
commit
8c923fc617
@ -369,7 +369,11 @@ bool GodotSharpBuilds::build_project_blocking(const String &p_config, const Vect
|
|||||||
MonoBuildInfo build_info(GodotSharpDirs::get_project_sln_path(), p_config);
|
MonoBuildInfo build_info(GodotSharpDirs::get_project_sln_path(), p_config);
|
||||||
|
|
||||||
// Add Godot defines
|
// Add Godot defines
|
||||||
|
#ifdef WINDOWS_ENABLED
|
||||||
String constants = "GodotDefineConstants=\"";
|
String constants = "GodotDefineConstants=\"";
|
||||||
|
#else
|
||||||
|
String constants = "GodotDefineConstants=\\\"";
|
||||||
|
#endif
|
||||||
|
|
||||||
for (int i = 0; i < p_godot_defines.size(); i++) {
|
for (int i = 0; i < p_godot_defines.size(); i++) {
|
||||||
constants += "GODOT_" + p_godot_defines[i].to_upper().replace("-", "_").replace(" ", "_").replace(";", "_") + ";";
|
constants += "GODOT_" + p_godot_defines[i].to_upper().replace("-", "_").replace(" ", "_").replace(";", "_") + ";";
|
||||||
@ -379,7 +383,11 @@ bool GodotSharpBuilds::build_project_blocking(const String &p_config, const Vect
|
|||||||
constants += "GODOT_REAL_T_IS_DOUBLE;";
|
constants += "GODOT_REAL_T_IS_DOUBLE;";
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef WINDOWS_ENABLED
|
||||||
constants += "\"";
|
constants += "\"";
|
||||||
|
#else
|
||||||
|
constants += "\\\"";
|
||||||
|
#endif
|
||||||
build_info.custom_props.push_back(constants);
|
build_info.custom_props.push_back(constants);
|
||||||
|
|
||||||
if (!GodotSharpBuilds::get_singleton()->build(build_info)) {
|
if (!GodotSharpBuilds::get_singleton()->build(build_info)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user