The Tcl cffi
package permits calling C functions in shared libraries from
within Tcl scripts via either the libffi
or dyncall
open source libraries.
The package supports Tcl 8.6 and 9.0+.
The source repository is at https://github.com/apnadkarni/tcl-cffi.
Documentation is at https://cffi.magicsplat.com. Some additional tutorial material is available at https://www.magicsplat.com/blog/tags/cffi/ and the samples in https://github.com/apnadkarni/tcl-cffi/tree/main/examples.
Source distributions and binary packages for some platforms can be downloaded from https://sourceforge.net/projects/magicsplat/files/cffi.
To build the package from the source, see BUILD.md
in the repository
or source distribution.
Major features of the package are
Limitations in the current version include
See the Change log.