Files
elixir-ffi/README.md
2015-09-21 19:12:06 -04:00

526 B

FFI

An easy way to call external functions (e.g. C functions) from Elixir.

Inspired by Ruby's FFI

** This is alpha software **

Example Program

defmodule MyLib do
  use FFI.Library

  ffi_lib "c"

  attach_function :puts, [:string], :int
end

MyLib.puts(["Hello world"])

Installation

hub clone joshnuss/elixir-ffi
cd elixir-ffi
make

Running Examples

mix run examples/basic.exs

License

MIT