configure.ac: use AX_DETECT_GIT_HEAD instead of inlined version