diff options
Diffstat (limited to 'third_party/packages/t/tomlc99')
-rw-r--r-- | third_party/packages/t/tomlc99/xmake.lua | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/third_party/packages/t/tomlc99/xmake.lua b/third_party/packages/t/tomlc99/xmake.lua new file mode 100644 index 0000000..2cc22b6 --- /dev/null +++ b/third_party/packages/t/tomlc99/xmake.lua @@ -0,0 +1,22 @@ +package("tomlc99") + +set_homepage("https://github.com/cktan/tomlc99") +set_description("TOML C library ") +set_license("MIT") + +set_urls("https://github.com/cktan/tomlc99.git") + +on_install("linux", "macosx", "windows", "mingw", function(package) + io.writefile("xmake.lua", [[ + add_rules("mode.debug", "mode.release") + target("tomlc99") + set_kind("static") + add_files("toml.c") + add_headerfiles("toml.h") + ]]) + import("package.tools.xmake").install(package) +end) + +on_test(function(package) + assert(package:has_cfuncs("toml_parse_file", { includes = "toml.h" })) +end) |