@@ -760,10 +760,10 @@ build_os
760760build_vendor
761761build_cpu
762762build
763- HAS_HG
764- HGBRANCH
765- HGTAG
766- HGVERSION
763+ HAS_GIT
764+ GITBRANCH
765+ GITTAG
766+ GITVERSION
767767BASECPPFLAGS
768768target_alias
769769host_alias
@@ -2698,17 +2698,17 @@ fi
26982698
26992699
27002700
2701- if test -e $srcdir /.hg/dirstate
2701+ if test -e $srcdir /.git/HEAD
27022702then
2703- # Extract the first word of "hg ", so it can be a program name with args.
2704- set dummy hg ; ac_word=$2
2703+ # Extract the first word of "git ", so it can be a program name with args.
2704+ set dummy git ; ac_word=$2
27052705{ $as_echo " $as_me :${as_lineno-$LINENO } : checking for $ac_word " >&5
27062706$as_echo_n " checking for $ac_word ... " >&6 ; }
2707- if ${ac_cv_prog_HAS_HG +: } false ; then :
2707+ if ${ac_cv_prog_HAS_GIT +: } false ; then :
27082708 $as_echo_n " (cached) " >&6
27092709else
2710- if test -n " $HAS_HG " ; then
2711- ac_cv_prog_HAS_HG =" $HAS_HG " # Let the user override the test.
2710+ if test -n " $HAS_GIT " ; then
2711+ ac_cv_prog_HAS_GIT =" $HAS_GIT " # Let the user override the test.
27122712else
27132713as_save_IFS=$IFS ; IFS=$PATH_SEPARATOR
27142714for as_dir in $PATH
@@ -2717,39 +2717,39 @@ do
27172717 test -z " $as_dir " && as_dir=.
27182718 for ac_exec_ext in ' ' $ac_executable_extensions ; do
27192719 if as_fn_executable_p " $as_dir /$ac_word$ac_exec_ext " ; then
2720- ac_cv_prog_HAS_HG =" found"
2720+ ac_cv_prog_HAS_GIT =" found"
27212721 $as_echo " $as_me :${as_lineno-$LINENO } : found $as_dir /$ac_word$ac_exec_ext " >&5
27222722 break 2
27232723 fi
27242724done
27252725 done
27262726IFS=$as_save_IFS
27272727
2728- test -z " $ac_cv_prog_HAS_HG " && ac_cv_prog_HAS_HG =" not-found"
2728+ test -z " $ac_cv_prog_HAS_GIT " && ac_cv_prog_HAS_GIT =" not-found"
27292729fi
27302730fi
2731- HAS_HG= $ac_cv_prog_HAS_HG
2732- if test -n " $HAS_HG " ; then
2733- { $as_echo " $as_me :${as_lineno-$LINENO } : result: $HAS_HG " >&5
2734- $as_echo " $HAS_HG " >&6 ; }
2731+ HAS_GIT= $ac_cv_prog_HAS_GIT
2732+ if test -n " $HAS_GIT " ; then
2733+ { $as_echo " $as_me :${as_lineno-$LINENO } : result: $HAS_GIT " >&5
2734+ $as_echo " $HAS_GIT " >&6 ; }
27352735else
27362736 { $as_echo " $as_me :${as_lineno-$LINENO } : result: no" >&5
27372737$as_echo " no" >&6 ; }
27382738fi
27392739
27402740
27412741else
2742- HAS_HG =no-repository
2742+ HAS_GIT =no-repository
27432743fi
2744- if test $HAS_HG = found
2744+ if test $HAS_GIT = found
27452745then
2746- HGVERSION= " hg id -i \$ (srcdir)"
2747- HGTAG= " hg id -t \$ (srcdir)"
2748- HGBRANCH= " hg id -b \$ (srcdir)"
2746+ GITVERSION= " git -C \$ (srcdir) rev-parse HEAD "
2747+ GITTAG= " git -C \$ (srcdir) name-rev --tags --name-only HEAD "
2748+ GITBRANCH= " git -C \$ (srcdir) name-rev --name-only HEAD "
27492749else
2750- HGVERSION =" "
2751- HGTAG =" "
2752- HGBRANCH =" "
2750+ GITVERSION =" "
2751+ GITTAG =" "
2752+ GITBRANCH =" "
27532753fi
27542754
27552755
0 commit comments