Add pthread library to linking flag
Add more warnings flags on compile
Merge branch 'master' into threaded-version

Conflicts:
	Makefile
Fix pi.c to avoid warnings messages on compile
Ensure random number function to randomize