From: Navarrop Date: Wed, 5 Oct 2011 13:36:26 +0000 (+0200) Subject: Test git version only on a git repository. X-Git-Tag: v3_6_2~3 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/71bcc9e07bd5799094b328f6dce1620efb40fdf5?ds=inline Test git version only on a git repository. --- diff --git a/buildtools/Cmake/CompleteInFiles.cmake b/buildtools/Cmake/CompleteInFiles.cmake index 465e61b645..a9bf4eaa3f 100644 --- a/buildtools/Cmake/CompleteInFiles.cmake +++ b/buildtools/Cmake/CompleteInFiles.cmake @@ -349,6 +349,7 @@ endif(pthread) ############### ## SVN version check ## +if(EXISTS .git) exec_program("git remote" OUTPUT_VARIABLE remote RETURN_VALUE ret) exec_program("git config --get remote.${remote}.url" OUTPUT_VARIABLE url RETURN_VALUE ret) @@ -362,7 +363,7 @@ if(url) STRING(REPLACE " " "~" GIT_DATE ${GIT_DATE}) STRING(REPLACE ":" "-" GIT_DATE ${GIT_DATE}) endif(url) - +endif(EXISTS .git) ################################### ## SimGrid and GRAS specific checks