summaryrefslogtreecommitdiff
path: root/Modules/CMakeDetermineCSharpCompiler.cmake
diff options
context:
space:
mode:
authorYoshinori Tahara <yossi-tahara@theolizer.com>2017-11-01 20:06:44 +0900
committerBrad King <brad.king@kitware.com>2017-11-07 08:23:16 -0500
commit04937db103541da442a426818c9314a423235858 (patch)
tree8c96e2f59e1f12d554756eb980bfdb46f203697b /Modules/CMakeDetermineCSharpCompiler.cmake
parenta91eb5e41f486628910f189bf40403568af013c7 (diff)
downloadcmake-04937db103541da442a426818c9314a423235858.tar.gz
CSharp: Fix compiler version detection in non-English languages
When we run `csc.exe /help` we look for "Version" in the output. Explicitly ask for the output in English. Reported-by: guttally@users.noreply.github.com
Diffstat (limited to 'Modules/CMakeDetermineCSharpCompiler.cmake')
-rw-r--r--Modules/CMakeDetermineCSharpCompiler.cmake2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/CMakeDetermineCSharpCompiler.cmake b/Modules/CMakeDetermineCSharpCompiler.cmake
index 55b2fb3039..eb825a5082 100644
--- a/Modules/CMakeDetermineCSharpCompiler.cmake
+++ b/Modules/CMakeDetermineCSharpCompiler.cmake
@@ -23,7 +23,7 @@ if(NOT CMAKE_CSharp_COMPILER_ID_RUN)
include(${CMAKE_ROOT}/Modules/CMakeDetermineCompilerId.cmake)
CMAKE_DETERMINE_COMPILER_ID(CSharp CSFLAGS CMakeCSharpCompilerId.cs)
- execute_process(COMMAND "${CMAKE_CSharp_COMPILER}" "/help" OUTPUT_VARIABLE output)
+ execute_process(COMMAND "${CMAKE_CSharp_COMPILER}" "/help /preferreduilang:en-US" OUTPUT_VARIABLE output)
string(REPLACE "\n" ";" output "${output}")
foreach(line ${output})
string(TOUPPER ${line} line)