From fad876f4250c76b4460086ffcc92ee7b1bc7f7a8 Mon Sep 17 00:00:00 2001 From: Xiang Zhang Date: Mon, 20 Aug 2018 22:36:19 +0800 Subject: [PATCH 1/2] bpo-30411: Use --git-dir instead of -C to make git work under version below 1.8.5. (GH-8744) (cherry picked from commit 4c8555773a801f957297132a92c0acb382d640e4) --- configure | 6 +++--- configure.ac | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/configure b/configure index a75ca3a0f5c9f2..03b73c6f135641 100755 --- a/configure +++ b/configure @@ -5791,9 +5791,9 @@ HAS_GIT=no-repository fi if test $HAS_GIT = found then - GITVERSION="git -C \$(srcdir) rev-parse --short HEAD" - GITTAG="git -C \$(srcdir) describe --all --always --dirty" - GITBRANCH="git -C \$(srcdir) name-rev --name-only HEAD" + GITVERSION="git --git-dir \$(srcdir)/.git rev-parse --short HEAD" + GITTAG="git --git-dir \$(srcdir)/.git describe --all --always --dirty" + GITBRANCH="git --git-dir \$(srcdir)/.git name-rev --name-only HEAD" else GITVERSION="" GITTAG="" diff --git a/configure.ac b/configure.ac index 36625f7b82a343..257c8eb21e54e8 100644 --- a/configure.ac +++ b/configure.ac @@ -1005,9 +1005,9 @@ HAS_GIT=no-repository fi if test $HAS_GIT = found then - GITVERSION="git -C \$(srcdir) rev-parse --short HEAD" - GITTAG="git -C \$(srcdir) describe --all --always --dirty" - GITBRANCH="git -C \$(srcdir) name-rev --name-only HEAD" + GITVERSION="git --git-dir \$(srcdir)/.git rev-parse --short HEAD" + GITTAG="git --git-dir \$(srcdir)/.git describe --all --always --dirty" + GITBRANCH="git --git-dir \$(srcdir)/.git name-rev --name-only HEAD" else GITVERSION="" GITTAG="" From a76d0afdc1072a5ec3e9719f6e806646655d6e95 Mon Sep 17 00:00:00 2001 From: Xiang Zhang Date: Mon, 20 Aug 2018 22:45:06 +0800 Subject: [PATCH 2/2] [2.7] bpo-30411: Use --git-dir instead of -C to make git work under version below 1.8.5. (GH-8744). (cherry picked from commit 4c8555773a801f957297132a92c0acb382d640e4) Co-authored-by: Xiang Zhang