xmake.lua 1.2 KB

12345678910111213141516171819202122232425262728293031323334
  1. package("imgui-color-text-edit")
  2. set_homepage("https://github.com/BalazsJako/ImGuiColorTextEdit")
  3. set_description("Colorizing text editor for ImGui")
  4. set_license("MIT")
  5. add_urls("https://github.com/BalazsJako/ImGuiColorTextEdit.git")
  6. add_versions("2019.06.15", "0a88824f7de8d0bd11d8419066caa7d3469395c4")
  7. add_deps("imgui")
  8. on_install("macosx", "linux", "windows", "mingw", "android", "iphoneos", function (package)
  9. io.writefile("xmake.lua", [[
  10. add_rules("mode.debug", "mode.release")
  11. set_languages("c++11")
  12. add_requires("imgui")
  13. add_packages("imgui")
  14. target("imgui-color-text-edit")
  15. set_kind("$(kind)")
  16. add_files("*.cpp")
  17. add_headerfiles("*.h")
  18. if is_plat("windows") and is_kind("shared") then
  19. add_rules("utils.symbols.export_all", {export_classes = true})
  20. end
  21. ]])
  22. import("package.tools.xmake").install(package)
  23. end)
  24. on_test(function (package)
  25. assert(package:check_cxxsnippets({test = [[
  26. void test() {
  27. TextEditor editor;
  28. }
  29. ]]}, {configs = {languages = "c++11"}, includes = "TextEditor.h"}))
  30. end)