From 923e685058c8854b21e48f69ebacdc414fcaa810 Mon Sep 17 00:00:00 2001 From: Etienne Cordonnier Date: Thu, 18 Jul 2019 14:02:50 +0200 Subject: [PATCH] cmake: fix git_describe not working with --dirty Signed-off-by: Etienne Cordonnier --- Source/cmake-modules/GetGitRevisionDescription.cmake | 6 ------ 1 file changed, 6 deletions(-) diff --git a/Source/cmake-modules/GetGitRevisionDescription.cmake b/Source/cmake-modules/GetGitRevisionDescription.cmake index 8ab03bc..dbaaa6a 100644 --- a/Source/cmake-modules/GetGitRevisionDescription.cmake +++ b/Source/cmake-modules/GetGitRevisionDescription.cmake @@ -90,15 +90,10 @@ function(git_describe _var) if(NOT GIT_FOUND) find_package(Git QUIET) endif() - get_git_head_revision(refspec hash) if(NOT GIT_FOUND) set(${_var} "GIT-NOTFOUND" PARENT_SCOPE) return() endif() - if(NOT hash) - set(${_var} "HEAD-HASH-NOTFOUND" PARENT_SCOPE) - return() - endif() # TODO sanitize #if((${ARGN}" MATCHES "&&") OR @@ -113,7 +108,6 @@ function(git_describe _var) execute_process(COMMAND "${GIT_EXECUTABLE}" describe - ${hash} ${ARGN} WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}" -- 2.17.1