diff options
| author | _ov4 <ov4@ov4.org> | 2026-10-18 08:41:32 +0000 |
|---|---|---|
| committer | _ov4 <ov4@ov4.org> | 2026-10-18 08:41:32 +0000 |
| commit | c5f103663bbee226d20bf6405457a62e7ec41611 (patch) | |
| tree | 930eca6113733ac45f5e97c2c375c4cb79f23425 /tools | |
| parent | 20a6c049f93e14e9c4faaa9d66e657732f86adb3 (diff) | |
fix(driver): include LLVM COFF helpers before Windows macros
Parse MinGWCOFF.h before windows.h so IMAGE_* macros do not replace LLVM
COFF enum declarations or their uses in the normalization helper.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'tools')
| -rw-r--r-- | tools/driver/EmbeddedRunner.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/driver/EmbeddedRunner.cc b/tools/driver/EmbeddedRunner.cc index 8950251..7bfbcf0 100644 --- a/tools/driver/EmbeddedRunner.cc +++ b/tools/driver/EmbeddedRunner.cc @@ -20,7 +20,6 @@ #ifndef NOMINMAX #define NOMINMAX #endif -#include <windows.h> #include <limits> #include "llvm/ExecutionEngine/JITLink/JITLink.h" #include "llvm/ExecutionEngine/JITLink/x86_64.h" @@ -28,6 +27,9 @@ #include "llvm/ExecutionEngine/Orc/Shared/WrapperFunctionUtils.h" #include "llvm/Support/Endian.h" #include "MinGWCOFF.h" +// Windows IMAGE_* macros conflict with LLVM COFF enums and inline helpers. +// Parse all LLVM COFF declarations and helpers before introducing those macros. +#include <windows.h> #endif namespace { |
