Adding missing pthread library to linker.

-lpthread was missing from Makefile