Skip to content

Commit

Permalink
antlr4-runtime: Fix build with latest msvc stl (#6403)
Browse files Browse the repository at this point in the history
* antlr4-runtime: Fix build with latest msvc stl

* Fix patch
  • Loading branch information
star-hengxing authored Feb 20, 2025
1 parent 42e710c commit 97843e5
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
13 changes: 13 additions & 0 deletions packages/a/antlr4-runtime/patches/4.13.2/add-include-chrono.patch
Original file line number Diff line number Diff line change
@@ -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 changes: 2 additions & 0 deletions packages/a/antlr4-runtime/xmake.lua
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 97843e5

Please sign in to comment.