fixed makefile not linking pthread