From f34b7e35cc1c636ae9f3656b3deba0597435a726 Mon Sep 17 00:00:00 2001 From: ruki Date: Thu, 16 Jul 2020 22:50:41 +0800 Subject: build lua-cjson --- core/src/lua-cjson/xmake.lua | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 core/src/lua-cjson/xmake.lua (limited to 'core/src/lua-cjson/xmake.lua') diff --git a/core/src/lua-cjson/xmake.lua b/core/src/lua-cjson/xmake.lua new file mode 100644 index 000000000..76caf9fc7 --- /dev/null +++ b/core/src/lua-cjson/xmake.lua @@ -0,0 +1,15 @@ +target("lua-cjson") + set_kind("static") + set_warnings("all") + add_deps("luajit") + if is_plat("windows") then + set_languages("c89") + end + 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") + if is_plat("windows") then + -- Windows sprintf()/strtod() handle NaN/inf differently. Not supported. + add_defines("DISABLE_INVALID_NUMBERS") + end + -- cgit v1.3.1