summaryrefslogtreecommitdiff
path: root/core/src/lua-cjson
diff options
context:
space:
mode:
authorruki <[email protected]>2023-01-19 23:12:14 +0800
committerruki <[email protected]>2023-01-19 23:12:14 +0800
commitc92a0248406711b5f1d6e27a22f45bab00dfc6b7 (patch)
tree8bc5814e7a3409bdf23448f0da2ff75485fbfa6d /core/src/lua-cjson
parent17978855ebb374e21593129b52d3266db7715eb5 (diff)
improve lua-cjson
Diffstat (limited to 'core/src/lua-cjson')
-rw-r--r--core/src/lua-cjson/xmake.lua1
-rwxr-xr-xcore/src/lua-cjson/xmake.sh1
2 files changed, 2 insertions, 0 deletions
diff --git a/core/src/lua-cjson/xmake.lua b/core/src/lua-cjson/xmake.lua
index 74406d67e..fa7855150 100644
--- a/core/src/lua-cjson/xmake.lua
+++ b/core/src/lua-cjson/xmake.lua
@@ -8,6 +8,7 @@ target("lua-cjson")
add_files("lua-cjson/*.c|fpconv.c")
-- Use internal strtod() / g_fmt() code for performance and disable multi-thread
add_defines("NDEBUG", "USE_INTERNAL_FPCONV")
+ add_defines("XM_CONFIG_API_HAVE_LUA_CJSON", {public = true})
if is_plat("windows") then
-- Windows sprintf()/strtod() handle NaN/inf differently. Not supported.
add_defines("DISABLE_INVALID_NUMBERS")
diff --git a/core/src/lua-cjson/xmake.sh b/core/src/lua-cjson/xmake.sh
index 134173051..f7d8b94b2 100755
--- a/core/src/lua-cjson/xmake.sh
+++ b/core/src/lua-cjson/xmake.sh
@@ -17,4 +17,5 @@ target "lua_cjson"
add_files "lua-cjson/g_fmt.c"
# Use internal strtod() / g_fmt() code for performance and disable multi-thread
add_defines "NDEBUG" "USE_INTERNAL_FPCONV"
+ add_defines "XM_CONFIG_API_HAVE_LUA_CJSON" "{public}"