Update libgit2 makefile to not fail on stale file (#22454)
When the timestamp of the original file changes compiliation will fail
on some systems due to permissions being set to `444`. Observed on Arch Linux.
According to the POSIX spec `cp -f` will on a failure unlink
the target file and retry, which should ignore the target file's permissions.
Co-authored-by: Tim Besard <tim.besard@gmail.com>
Co-authored-by: Simon Byrne <simonbyrne@gmail.com>