diff --git a/programs/platform.h b/programs/platform.h index 64ecd21f..31820631 100644 --- a/programs/platform.h +++ b/programs/platform.h @@ -90,7 +90,7 @@ extern "C" { && ( defined(__unix__) || defined(__unix) \ || defined(__midipix__) || defined(__VMS) || defined(__HAIKU__) ) -# if defined(__linux__) || defined(__linux) +# if defined(__linux__) || defined(__linux) || defined(__CYGWIN__) # ifndef _POSIX_C_SOURCE # define _POSIX_C_SOURCE 200809L /* feature test macro : https://www.gnu.org/software/libc/manual/html_node/Feature-Test-Macros.html */ # endif @@ -123,11 +123,11 @@ extern "C" { ************************************************/ #if (defined(__linux__) && (PLATFORM_POSIX_VERSION > 1)) \ || (PLATFORM_POSIX_VERSION >= 200112L) \ - || defined(__DJGPP__) \ - || defined(__MSYS__) + || defined(__DJGPP__) # include /* isatty */ +# include /* fileno */ # define IS_CONSOLE(stdStream) isatty(fileno(stdStream)) -#elif defined(MSDOS) || defined(OS2) || defined(__CYGWIN__) +#elif defined(MSDOS) || defined(OS2) # include /* _isatty */ # define IS_CONSOLE(stdStream) _isatty(_fileno(stdStream)) #elif defined(WIN32) || defined(_WIN32)