From 7bb1d28f8343488bc4b2aa237be2574c174ecc29 Mon Sep 17 00:00:00 2001 From: Augustin Trancart Date: Mon, 27 Oct 2025 11:55:22 +0100 Subject: [PATCH] Don't use AC_CHECK_FILE, not supported when cross-compiling --- configure.ac | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index cd26ac54..650c7031 100644 --- a/configure.ac +++ b/configure.ac @@ -58,7 +58,12 @@ dnl Version Information imported from Version.config and Git dnl =========================================================================== AC_CHECK_PROG([GITCMD], [git —version], [yes], [no]) -AC_CHECK_FILE([.git], [DOTGITDIR=yes], [DOTGITDIR=no]) +# Note: AC_CHECK_FILE doesn't work when cross-compiling +if test -d .git; then + DOTGITDIR=yes +else + DOTGITDIR=no +fi if test "x${GITCMD}" = "xyes" -a "x${DOTGITDIR}" = "xyes"; then GIT_COMMIT_HASH=" $(git rev-parse --short HEAD)" else