We should really check whether pthread_once() is in libc so that then we
don't have to add an unnecessary dependency on -lpthread.
Also, we have a proper once implementation that we could use when we
don't have pthread_once(), so we should fallback on that if we detect
that we have neither pthread_once() in libc and --disable-pthread is
given.