Add pthread as a dependency