Complete rust bindings to the capstone engine. Currently only Linux and OS X is supported. Building on windows should work, but I currently can't test that. A nightly version of Rust is also required.
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
You'll need to have installed the capstone engine.
You can set the environment variable CAPSTONE_INCLUDE_DIR
to the directory where the header files for the capstone engine are.
The environment variable CAPSTONE_LIBRARY_DIR
specifies the library directory where capstone is installed.
These default to /usr/include
and /usr/lib
on Linux and OS X.
On windows there are no default library and include directories so you must specify these environment variables.
Then you can simply git clone
this repository and cd
into it.
To build this project simply execute cargo build
.
Examples can be found in the examples directory.
Simply execute cargo test
.
capstone-rs
does not have complete bindings to the capstone engine. For example, cs_detail
is completly missing and also many constants
are missing.
libcapstone-sys generates bindings directly from the capstone headers, so nothing is missing!
However that results in an not rust like API, for which libcapstone exists.
This project is licensed under the MIT License - see the LICENSE.md file for details