summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorIgnacio Roldán Etcheverry <neikeq@users.noreply.github.com>2019-03-20 18:30:31 +0100
committerGitHub <noreply@github.com>2019-03-20 18:30:31 +0100
commitb0fbefe9da2402110dae3d2f074703218aa9d397 (patch)
tree641f379f36684c3034a26dce904d2b92c5b5edfc /modules
parenta53645e726097e9020d12df886b62431cb1740b9 (diff)
parent7440295ad1cd94b4066733cc20680429ca690f2d (diff)
Merge pull request #27271 from shartte/fix-msbuild-detection
Add support for new MSBuild directory naming introduced in VS 2019
Diffstat (limited to 'modules')
-rw-r--r--modules/mono/utils/mono_reg_utils.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/modules/mono/utils/mono_reg_utils.cpp b/modules/mono/utils/mono_reg_utils.cpp
index 0eb4b3b8b3..d7f9b22c31 100644
--- a/modules/mono/utils/mono_reg_utils.cpp
+++ b/modules/mono/utils/mono_reg_utils.cpp
@@ -29,6 +29,7 @@
/*************************************************************************/
#include "mono_reg_utils.h"
+#include "core/os/dir_access.h"
#ifdef WINDOWS_ENABLED
@@ -200,6 +201,13 @@ String find_msbuild_tools_path() {
val += "\\";
}
+ // Since VS2019, the directory is simply named "Current"
+ String msBuildDirectory = val + "MSBuild\\Current\\Bin";
+ if (DirAccess::exists(msBuildDirectory)) {
+ return msBuildDirectory;
+ }
+
+ // Directory name "15.0" is used in VS 2017
return val + "MSBuild\\15.0\\Bin";
}
}