Link against pthread as well.