diff --git a/xmake.lua b/xmake.lua index 99aca44f..09b20365 100644 --- a/xmake.lua +++ b/xmake.lua @@ -11,10 +11,6 @@ set_encodings("utf-8") -- add rules add_rules("mode.debug", "mode.releasedbg") --- require packages -add_requires("xbyak") -add_requires("spdlog", { configs = { header_only = false, std_format = true } }) - -- make extras available includes("xmake-extra.lua") @@ -25,6 +21,13 @@ option("sfse_xbyak", function() add_defines("SFSE_SUPPORT_XBYAK=1") end) +-- require packages +add_requires("spdlog", { configs = { header_only = false, std_format = true } }) + +if has_config("sfse_xbyak") then + add_requires("xbyak") +end + -- define targets target("commonlibsf") -- set target kind