On some compilers the syntax `#ifndef std::fopen` will always lead to compilation error. Avoid generating it in the check.