C++ standard finally defined pi. Compilers should catch up within a few years.
Once this feature becomes common (when the g++ compiler for the top distro on distrowatch defaults to support it),
insert the code:
#include <numbers>
using std::numbers::pi;
and rename M_PI to pi throughout Turtle.cpp
Until then, if your compiler no longer provides the old M_PI definition, you can define it on the compiler command line.
e.g. change g++ to g++ -DM_PI=3.14159 wherever g++ is called to compile the program.