Skip to content

Latest commit

 

History

History
37 lines (27 loc) · 1.16 KB

README.md

File metadata and controls

37 lines (27 loc) · 1.16 KB

Rust FFI Generator

The Rust FFI generator is a yeoman generator for bootstraping Rust libraries that expose Foreign Function Interface bindings for other languages (currently only NPM is supported).

This project was inspired by Zbigniew Siciarz's blog post on calling Rust from other languages.

In order to use this properly, you will obviously need Rust installed. The current convention for this is to use the lastest Nightly Release. Instructions for this can be found in the Rust Book.

Install

Install Yeoman (best when installed globally).

npm install -g yo

Install this generator.

npm install -g generator-rust-ffi

Create a folder for your project to live.

mkdir a-rust-lib && cd a-rust-lib

Finally, initiate the generator.

yo rust-ffi

Binding-Specific Install

You will also need to install tools required by the bindings you create (obviously).

JavaScript (nodejs/io.js)

You need to install a modern version of nodejs/io.js (v0.10+).

License

MIT