xbps_archive_fetch_xxx: avoid races with multiple threads in the libfetch code.

Protect our critical sections with a mutex for now, until libfetch
is really fixed to work correctly with multiple threads.