package ctypes

  1. Overview
  2. Docs
Combinators for binding to C libraries without writing any C

Install

dune-project
 Dependency

Authors

Maintainers

Sources

0.20.1.tar.gz
sha256=78bf1acbc152a2e455a452e72eb75c3d4cefa366f2708cced3e7fe24b6278ec7
md5=91211baac16cb43134b1d6009b1edf92

Description

ctypes is a library for binding to C libraries using pure OCaml. The primary aim is to make writing C extensions as straightforward as possible.

The core of ctypes is a set of combinators for describing the structure of C types -- numeric types, arrays, pointers, structs, unions and functions. You can use these combinators to describe the types of the functions that you want to call, then bind directly to those functions -- all without writing or generating any C!

To install the optional ctypes.foreign interface (which uses libffi to provide dynamic access to foreign libraries), you will need to also install the ctypes-foreign optional dependency:

opam install ctypes ctypes-foreign

This will make the ctypes.foreign ocamlfind subpackage available.

Added to opam-repository:

Dependencies (4)

  1. bigarray-compat
  2. ocamlfind build
  3. integers >= "0.3.0"
  4. ocaml >= "4.03.0" & < "5.2"

Dev Dependencies (4)

  1. conf-ncurses with-test
  2. ounit with-test
  3. ctypes-foreign with-test
  4. lwt with-test & >= "3.2.0"

  1. ahrocksdb
  2. antic < "0.4.0"
  3. arb < "0.4.0"
  4. argon2
  5. arrayjit < "0.4.1"
  6. async_ssl >= "v0.15.0"
  7. bimage-unix
  8. binaryen_dsl
  9. bitgenerators
  10. calcium < "0.4.0"
  11. ceph
  12. cf
  13. checked_oint < "0.4.1"
  14. cmark
  15. cmarker
  16. ctypes-build
  17. ctypes-foreign = "0.18.0"
  18. ctypes-zarith
  19. ctypes_stubs_js
  20. cudajit
  21. decompress >= "1.3.0" & < "1.5.3"
  22. directories
  23. dlm >= "0.3.3"
  24. dune >= "3.17.2"
  25. echo
  26. eigen >= "0.1.0"
  27. extism < "1.1.0"
  28. flint
  29. fsevents
  30. gccjit
  31. gdal >= "0.10.0"
  32. gl-legacy
  33. gobject-introspection
  34. gpiod
  35. gr
  36. guile
  37. hacl-star-raw >= "0.3.2"
  38. hardcaml_c
  39. hardcaml_verilator
  40. hdr_histogram
  41. hegel
  42. imguiml
  43. keynub-licdongle
  44. kqueue < "0.2.0"
  45. libdash = "0.3"
  46. libirmin
  47. libudev
  48. lilv
  49. llvm >= "3.7"
  50. lp-glpk
  51. lp-gurobi
  52. luv
  53. luv_unix
  54. lz4
  55. mariadb
  56. memcpy >= "0.2.1"
  57. metal
  58. mmdb
  59. mpg123
  60. netlink
  61. opasswd
  62. opencc < "transition"
  63. opencc0
  64. opencc1
  65. opencc1_1
  66. orocksdb
  67. osx-acl
  68. osx-attr
  69. osx-cf
  70. osx-fsevents
  71. osx-membership
  72. osx-mount
  73. osx-secure-transport
  74. osx-xattr
  75. owl >= "0.9.0"
  76. pari
  77. pari-bindings
  78. pci
  79. pg_query
  80. pkcs11-driver
  81. pkcs11-rev
  82. portaudio_c_bindings
  83. posix-base < "4.0.1"
  84. posix-bindings < "3"
  85. posix-errno
  86. posix-getopt >= "2.0.0"
  87. posix-math2
  88. posix-resource
  89. posix-signal
  90. posix-socket
  91. posix-socket-unix
  92. posix-stat
  93. posix-time2
  94. posix-types
  95. posix-uname
  96. posix-unistd
  97. ppx_cstubs = "0.5.1" | >= "0.7.0"
  98. py >= "1.1"
  99. quickjs < "0.5.0"
  100. raygui < "1.5.1"
  101. raylib < "1.5.1"
  102. reed-solomon-erasure
  103. rfc1951 >= "1.3.0" & < "1.6.0"
  104. sanlock
  105. sarek
  106. sattools
  107. sodium < "0.6.0"
  108. spin >= "0.8.0"
  109. spoc
  110. srt < "0.3.4"
  111. stk_iconv
  112. swipl
  113. sys-socket
  114. sys-socket-unix
  115. tensorflow
  116. tgls < "0.9.0"
  117. torch
  118. tsdl < "1.1.0"
  119. tsdl-image >= "0.3.0"
  120. tsdl-mixer
  121. tsdl-ttf >= "0.3"
  122. unix-errno >= "0.4.1" & < "0.5.0" | >= "0.6.0"
  123. unix-sys-resource
  124. unix-sys-stat
  125. unix-time
  126. unix-type-representations >= "0.1.1"
  127. uring-trace
  128. wasmer
  129. wasmtime
  130. xedbindings
  131. xgboost
  132. xxhash
  133. yaml
  134. yara
  135. yices2_bindings
  136. zstandard
  137. zstd >= "0.3"

Conflicts (2)

  1. host-system-msvc
  2. mirage-xen >= "6.0.0"