Use libgit2 with threads

Signed-off-by: Sven Strickroth <email@cs-ware.de>