xmake.lua 1.1 KB

12345678910111213141516171819202122232425262728
  1. package("libxshmfence")
  2. set_homepage("https://www.x.org/")
  3. set_description("X.Org: Shared memory 'SyncFence' synchronization primitive")
  4. set_urls("https://www.x.org/archive/individual/lib/libxshmfence-$(version).tar.gz")
  5. add_versions("1.3", "7eb3d46ad91bab444f121d475b11b39273142d090f7e9ac43e6a87f4ff5f902c")
  6. add_versions("1.3.3", "6233ccd9fa80198835efc3039cdf8086ab2b218b17e77ebdb0a19913fcee58d3")
  7. if is_plat("linux") then
  8. add_extsources("apt::libxshmfence-dev")
  9. end
  10. if is_plat("macosx", "linux") then
  11. add_deps("pkg-config", "xorgproto")
  12. end
  13. on_install("macosx", "linux", function (package)
  14. local configs = {"--sysconfdir=" .. package:installdir("etc"),
  15. "--localstatedir=" .. package:installdir("var"),
  16. "--disable-dependency-tracking",
  17. "--disable-silent-rules"}
  18. import("package.tools.autoconf").install(package, configs)
  19. end)
  20. on_test(function (package)
  21. assert(package:has_ctypes("struct xshmfence", {includes = "X11/xshmfence.h"}))
  22. end)