Add M_PI which isn't defined by gcc with std=c++11.