[Cmake-commits] CMake branch, next, updated. v2.8.2-1085-gcea559d

Alexander Neundorf neundorf at kde.org
Mon Oct 18 15:48:05 EDT 2010


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".

The branch, next has been updated
       via  cea559d2c4e2c691792da7b95533d717b79241a9 (commit)
       via  506805c999a5b91130e4811607a261117354d40a (commit)
       via  00b327fed857ac1b7f21b941733be2f0e79f0d6f (commit)
       via  76c8c6017c045f6b2390149a87c1c69b9166bedc (commit)
       via  0dc88cf8533fd3e7ba1b3322fc279c158b17b59f (commit)
      from  cde67a278ce98e5639cd87223ad376a9cd74e724 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=cea559d2c4e2c691792da7b95533d717b79241a9
commit cea559d2c4e2c691792da7b95533d717b79241a9
Merge: cde67a2 506805c
Author:     Alex Neundorf <neundorf at kde.org>
AuthorDate: Mon Oct 18 21:46:13 2010 +0200
Commit:     Alex Neundorf <neundorf at kde.org>
CommitDate: Mon Oct 18 21:46:13 2010 +0200

    Merge branch 'FixBisonWithLocale' into next


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=506805c999a5b91130e4811607a261117354d40a
commit 506805c999a5b91130e4811607a261117354d40a
Author:     Alex Neundorf <neundorf at kde.org>
AuthorDate: Mon Oct 18 21:44:42 2010 +0200
Commit:     Alex Neundorf <neundorf at kde.org>
CommitDate: Mon Oct 18 21:44:42 2010 +0200

    Make FindBISON work properly with non-C locales (#11326)
    
    Applying the patch attached to http://public.kitware.com/Bug/view.php?id=11326
    It sets LC_ALL to C before calling execute_process(), so the output is
    in english.
    
    Alex

diff --git a/Modules/FindBISON.cmake b/Modules/FindBISON.cmake
index 6021b12..fc5daa6 100644
--- a/Modules/FindBISON.cmake
+++ b/Modules/FindBISON.cmake
@@ -51,12 +51,19 @@ FIND_PROGRAM(BISON_EXECUTABLE bison DOC "path to the bison executable")
 MARK_AS_ADVANCED(BISON_EXECUTABLE)
 
 IF(BISON_EXECUTABLE)
+  # the bison commands should be executed with the C locale, otherwise
+  # the message (which are parsed) may be translated
+  SET(_Bison_SAVED_LC_ALL "$ENV{LC_ALL}")
+  SET(ENV{LC_ALL} C)
 
   EXECUTE_PROCESS(COMMAND ${BISON_EXECUTABLE} --version
     OUTPUT_VARIABLE BISON_version_output
     ERROR_VARIABLE BISON_version_error
     RESULT_VARIABLE BISON_version_result
     OUTPUT_STRIP_TRAILING_WHITESPACE)
+
+  SET(ENV{LC_ALL} ${_Bison_SAVED_LC_ALL})
+
   IF(NOT ${BISON_version_result} EQUAL 0)
     MESSAGE(SEND_ERROR "Command \"${BISON_EXECUTABLE} --version\" failed with output:\n${BISON_version_error}")
   ELSE()
@@ -115,7 +122,7 @@ IF(BISON_EXECUTABLE)
         IF("${ARGV5}" STREQUAL "VERBOSE")
           BISON_TARGET_option_verbose(${Name} ${BisonOutput} "${ARGV6}")
         ENDIF()
-      
+
         IF("${ARGV5}" STREQUAL "COMPILE_FLAGS")
           BISON_TARGET_option_extraopts("${ARGV6}")
         ENDIF()
@@ -125,10 +132,10 @@ IF(BISON_EXECUTABLE)
       LIST(APPEND BISON_TARGET_cmdopt "-d")
       STRING(REGEX REPLACE "^(.*)(\\.[^.]*)$" "\\2" _fileext "${ARGV2}")
       STRING(REPLACE "c" "h" _fileext ${_fileext})
-      STRING(REGEX REPLACE "^(.*)(\\.[^.]*)$" "\\1${_fileext}" 
+      STRING(REGEX REPLACE "^(.*)(\\.[^.]*)$" "\\1${_fileext}"
           BISON_${Name}_OUTPUT_HEADER "${ARGV2}")
       LIST(APPEND BISON_TARGET_outputs "${BISON_${Name}_OUTPUT_HEADER}")
-        
+
       ADD_CUSTOM_COMMAND(OUTPUT ${BISON_TARGET_outputs}
         ${BISON_TARGET_extraoutputs}
         COMMAND ${BISON_EXECUTABLE}
@@ -136,7 +143,7 @@ IF(BISON_EXECUTABLE)
         DEPENDS ${ARGV1}
         COMMENT "[BISON][${Name}] Building parser with bison ${BISON_VERSION}"
         WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR})
-    
+
       # define target variables
       SET(BISON_${Name}_DEFINED TRUE)
       SET(BISON_${Name}_INPUT ${ARGV1})

-----------------------------------------------------------------------

Summary of changes:
 Modules/FindBISON.cmake           |   15 +++++++++++----
 Source/kwsys/kwsysDateStamp.cmake |    2 +-
 2 files changed, 12 insertions(+), 5 deletions(-)


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list