From: Nabil Ghodbane Date: Thu, 15 Oct 2020 14:17:14 +0000 (+0200) Subject: spns #19085: handle LC_ALL environment variable issue fixed by Vadim X-Git-Tag: V9_6_0~10 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=c296662ff8fce66fabcf62b59031a0be01f0640a;p=tools%2Fsat_salome.git spns #19085: handle LC_ALL environment variable issue fixed by Vadim --- diff --git a/products/cmake.pyconf b/products/cmake.pyconf index 898e608..9bd309b 100644 --- a/products/cmake.pyconf +++ b/products/cmake.pyconf @@ -4,6 +4,7 @@ default : build_source : "script" compil_script : $name + $VARS.scriptExtension get_source : "archive" + patches: [] system_info : { rpm : [] @@ -25,3 +26,13 @@ default : compile_time : "yes" } } + +version_3_12_1: +{ + patches : ['cmake-3.12.1.patch'] # spns #19085 +} + +version_3_12_1_win: +{ + patches : [] +} \ No newline at end of file diff --git a/products/patches/cmake-3.12.1.patch b/products/patches/cmake-3.12.1.patch new file mode 100644 index 0000000..5e5c241 --- /dev/null +++ b/products/patches/cmake-3.12.1.patch @@ -0,0 +1,29 @@ +diff -Naur --exclude=CVS --exclude=.git --exclude=.hg cmake-3.12.1.orig/Modules/CheckCXXCompilerFlag.cmake cmake-3.12.1.new/Modules/CheckCXXCompilerFlag.cmake +--- cmake-3.12.1.orig/Modules/CheckCXXCompilerFlag.cmake 2018-08-09 15:14:07.000000000 +0300 ++++ cmake-3.12.1.new/Modules/CheckCXXCompilerFlag.cmake 2020-08-03 14:51:05.000000000 +0300 +@@ -43,8 +43,10 @@ + # Normalize locale during test compilation. + set(_CheckCXXCompilerFlag_LOCALE_VARS LC_ALL LC_MESSAGES LANG) + foreach(v ${_CheckCXXCompilerFlag_LOCALE_VARS}) +- set(_CheckCXXCompilerFlag_SAVED_${v} "$ENV{${v}}") +- set(ENV{${v}} C) ++ if("$ENV{${v}}") ++ set(_CheckCXXCompilerFlag_SAVED_${v} "$ENV{${v}}") ++ set(ENV{${v}} C) ++ endif() + endforeach() + CHECK_COMPILER_FLAG_COMMON_PATTERNS(_CheckCXXCompilerFlag_COMMON_PATTERNS) + CHECK_CXX_SOURCE_COMPILES("int main() { return 0; }" ${_RESULT} +@@ -53,8 +55,10 @@ + ${_CheckCXXCompilerFlag_COMMON_PATTERNS} + ) + foreach(v ${_CheckCXXCompilerFlag_LOCALE_VARS}) +- set(ENV{${v}} ${_CheckCXXCompilerFlag_SAVED_${v}}) +- unset(_CheckCXXCompilerFlag_SAVED_${v}) ++ if("${_CheckCXXCompilerFlag_SAVED_${v}}") ++ set(ENV{${v}} ${_CheckCXXCompilerFlag_SAVED_${v}}) ++ unset(_CheckCXXCompilerFlag_SAVED_${v}) ++ endif() + endforeach() + unset(_CheckCXXCompilerFlag_LOCALE_VARS) + unset(_CheckCXXCompilerFlag_COMMON_PATTERNS)