summaryrefslogtreecommitdiff
path: root/core/src/lua-cjson/xmake.lua
blob: 76caf9fc73bb48cfa82c471ed41c3fb2733d35e7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
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