Recent git versions place the submodule git repos into the
.git/modules directory of the toplevel repo.  In that case
.git of the seabios tree isn't a directory, but a regular
file, saying where the gitdir is.

Extent the git check to also allow .git being a regular file,
so works correctly when called within the qemu

Signed-off-by: Gerd Hoffmann <>
(cherry picked from commit 0b3607f89ac24f84f8b22ffaadb4f0fd111bda24)
1 file changed