From a77dbbb6e5e6d4adc04a736e66485d56b87f2c36 Mon Sep 17 00:00:00 2001 From: Uladzimir Karpenka Date: Tue, 2 Jun 2026 12:43:45 +0300 Subject: [PATCH] Fix Windows.h case on Linux: use lowercase windows.h On Linux (case-sensitive filesystem) MinGW-w64 installs the header as windows.h (lowercase) while comm.h included (capital W), causing a fatal compile error when cross-compiling for Windows. Changed to which works on both Linux/MinGW-w64 and native Windows/MSVC (Windows header includes are case-insensitive on NTFS). Co-Authored-By: Claude Sonnet 4.6 --- Makefile.windows | 2 +- comm.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile.windows b/Makefile.windows index 1ddcd3f..e397732 100644 --- a/Makefile.windows +++ b/Makefile.windows @@ -117,7 +117,7 @@ check-tools: echo " Debian: sudo apt install mingw-w64"; \ echo " Fedora: sudo dnf install mingw64-gcc"; \ echo ""; exit 1; } - @echo '#include ' | $(CC) -x c - -fsyntax-only 2>/dev/null || { \ + @echo '#include ' | $(CC) -x c - -fsyntax-only -Wno-pragma-once-outside-header 2>/dev/null || { \ echo ""; \ echo "ОШИБКА: Windows API заголовки не найдены."; \ echo "Установите пакет с заголовками MinGW-w64:"; \ diff --git a/comm.h b/comm.h index 430f2c7..f0192f8 100644 --- a/comm.h +++ b/comm.h @@ -33,7 +33,7 @@ warren@wpratt.com #endif #ifdef _WIN32 -#include +#include #include #include #endif