Re-enable thread safety with the cmake builds (#41)