diff --git a/CMakeModules/WriteVersionHeader.cmake b/CMakeModules/WriteVersionHeader.cmake index da1b9a4168..fa10f23362 100644 --- a/CMakeModules/WriteVersionHeader.cmake +++ b/CMakeModules/WriteVersionHeader.cmake @@ -22,20 +22,16 @@ # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA # -# Automagically create version header file if the version string was not defined during -# the build configuration. If CreateBzrVersionHeader or CreateGitVersionHeader cannot -# determine the current repo version, a version.h file is still created with -# KICAD_BUILD_VERSION set to "no-vcs-found". +# Automagically create version header file if the version string was +# not defined during the build configuration. If +# CreateGitVersionHeader cannot determine the current repo version, a +# version.h file is still created with KICAD_BUILD_VERSION set to +# "no-vcs-found". if( NOT KICAD_BUILD_VERSION ) set( _wvh_version_str "no-vcs-found" ) - # Detect the appropiate VCS and set the version string. - if( EXISTS "${SRC_PATH}/.bzr" ) - message( STATUS "Using Bazaar to determine build version string." ) - include( ${CMAKE_MODULE_PATH}/CreateBzrVersionHeader.cmake ) - create_bzr_version_header( ${SRC_PATH} ) - set( _wvh_version_str ${KICAD_BUILD_VERSION} ) - elseif( EXISTS "${SRC_PATH}/.git" ) + # Attempt to detect if we have a git repo and set the version string. + if( EXISTS "${SRC_PATH}/.git" ) message( STATUS "Using Git to determine build version string." ) include( ${CMAKE_MODULE_PATH}/CreateGitVersionHeader.cmake ) create_git_version_header( ${SRC_PATH} )