EOF not defined for Ubuntu build, so included cstdio