x11pragma.nim 571 B

123456789101112131415161718192021
  1. # included from xlib bindings
  2. when defined(use_pkg_config) or defined(use_pkg_config_static):
  3. {.pragma: libx11, cdecl, importc.}
  4. {.pragma: libx11c, cdecl.}
  5. when defined(use_pkg_config_static):
  6. {.passl: gorge("pkg-config x11 --static --libs").}
  7. else:
  8. {.passl: gorge("pkg-config x11 --libs").}
  9. else:
  10. when defined(macosx):
  11. const
  12. libX11* = "libX11.dylib"
  13. else:
  14. const
  15. libX11* = "libX11.so(|.6)"
  16. {.pragma: libx11, cdecl, dynlib: libX11, importc.}
  17. {.pragma: libx11c, cdecl, dynlib: libX11.}