xmake.lua 919 B

123456789101112131415161718192021222324
  1. package("nmd")
  2. set_kind("library", {headeronly = true})
  3. set_homepage("https://github.com/Nomade040/nmd")
  4. set_description("An x86 assembler and disassembler along with a C89 header file (nmd_assembly.h), and a C89 2D graphics library (nmd_graphics.h).")
  5. set_license("Unlicense")
  6. add_urls("https://github.com/Nomade040/nmd.git")
  7. add_versions("2021.03.28", "33ac3b62c7d1eb28ae6b71d4dd78aa133ef96488")
  8. add_includedirs("include", "include/nmd")
  9. on_install(function (package)
  10. os.cp("nmd_assembly.h", package:installdir("include/nmd"))
  11. os.cp("nmd_graphics.h", package:installdir("include/nmd"))
  12. end)
  13. on_test(function (package)
  14. assert(package:check_cxxsnippets({test = [[
  15. #include <nmd/nmd_assembly.h>
  16. void test() {
  17. nmd_x86_instruction instruction;
  18. }
  19. ]]}, {configs = {languages = "c89"}}))
  20. end)