Browse Source

antlr4-runtime: Fix build with latest msvc stl (#6403)

* antlr4-runtime: Fix build with latest msvc stl

* Fix patch
star9029 6 months ago
parent
commit
97843e50e7

+ 13 - 0
packages/a/antlr4-runtime/patches/4.13.2/add-include-chrono.patch

@@ -0,0 +1,13 @@
+diff --git a/runtime/Cpp/runtime/src/atn/ProfilingATNSimulator.cpp b/runtime/Cpp/runtime/src/atn/ProfilingATNSimulator.cpp
+index 9fd86d6..5220492 100644
+--- a/runtime/Cpp/runtime/src/atn/ProfilingATNSimulator.cpp
++++ b/runtime/Cpp/runtime/src/atn/ProfilingATNSimulator.cpp
+@@ -10,6 +10,7 @@
+ #include "support/CPPUtils.h"
+ 
+ #include "atn/ProfilingATNSimulator.h"
++#include <chrono>
+ 
+ using namespace antlr4;
+ using namespace antlr4::atn;
+ 

+ 2 - 0
packages/a/antlr4-runtime/xmake.lua

@@ -9,6 +9,8 @@ package("antlr4-runtime")
     add_versions("4.13.2", "9f18272a9b32b622835a3365f850dd1063d60f5045fb1e12ce475ae6e18a35bb")
     add_versions("4.13.1", "da20d487524d7f0a8b13f73a8dc326de7fc2e5775f5a49693c0a4e59c6b1410c")
 
+    add_patches("4.13.2", "patches/4.13.2/add-include-chrono.patch", "79400e790cc757760a292168a52762e6e2b91045190231fdf06cba60a164309e")
+
     if is_plat("mingw") and is_subhost("msys") then
         add_extsources("pacman::antlr4-runtime-cpp")
     elseif is_plat("linux") then