Fix variable naming bug causing the bzr version to be dropped in FindBazaar.cmake.

This commit is contained in:
Wayne Stambaugh 2015-01-16 09:14:51 -05:00
parent d477004436
commit 7ec906a373
1 changed files with 3 additions and 3 deletions

View File

@ -54,15 +54,15 @@ if( Bazaar_EXECUTABLE )
# Fetch the Bazaar executable version. # Fetch the Bazaar executable version.
execute_process( COMMAND ${Bazaar_EXECUTABLE} --version execute_process( COMMAND ${Bazaar_EXECUTABLE} --version
OUTPUT_VARIABLE bzr_version_output OUTPUT_VARIABLE _bzr_version_output
ERROR_VARIABLE _bzr_version_error ERROR_VARIABLE _bzr_version_error
RESULT_VARIABLE _bzr_version_result RESULT_VARIABLE _bzr_version_result
OUTPUT_STRIP_TRAILING_WHITESPACE ) OUTPUT_STRIP_TRAILING_WHITESPACE )
if( ${_bzr_version_result} EQUAL 0 ) if( ${_bzr_version_result} EQUAL 0 )
set( Bazaar_FOUND TRUE ) set( Bazaar_FOUND TRUE )
string( REGEX REPLACE "^(.*\n)? \(bzr\) ([^\n]+).*" string( REGEX REPLACE "^[\n]*Bazaar \\(bzr\\) ([0-9.a-z]+).*"
"\\2" Bazaar_VERSION "${_bzr_version_output}" ) "\\1" Bazaar_VERSION "${_bzr_version_output}" )
message( STATUS "Bazaar version control system version ${Bazaar_VERSION} found." ) message( STATUS "Bazaar version control system version ${Bazaar_VERSION} found." )
endif( ${_bzr_version_result} EQUAL 0 ) endif( ${_bzr_version_result} EQUAL 0 )