(Apple OSX) Build with HAVE_THREADS defined