Use cmath functions instead of macros from math.h which gcc hides