init pthread mutexes only if an initializer exists