Add check for modf and link with -lm if it's not in libc. Needed for