JIT-compiler for the programming language Dora implemented in Rust. Works on Linux (x86_64, aarch64) and macOS (x86_64). Build with:
You need to install these dependencies:
llvm - Download LLVM 5.0.0 from llvm.org.
Unpack the archive and switch into the source directory $LLVM_SRC_DIR
(e.g. $HOME/llvm-5.0.0.src
).
We will now build & install LLVM to $LLVM_INSTALL_DIR
(e.g. $HOME/llvm-5.0.0
).
cd $LLVM_SRC_DIR # change into directory with LLVM source
cmake -G Ninja . -DLLVM_ENABLE_ASSERTIONS=on \
-DCMAKE_INSTALL_PREFIX=$LLVM_INSTALL_DIR \
-DCMAKE_BUILD_TYPE=Debug \
-DLLVM_TARGETS_TO_BUILD=X86 \
cmake --build . --target install
You can find more information on building LLVM, in its documentation.
$ git clone https://github.com/aquynh/capstone
$ cd capstone && git checkout 3.0.4 && sudo make install
# on MacOS capstone can be installed via homebrew
$ brew install capstone
ruby - used to run tests
Install current Rust Nightly via rustup.rs. The nightly version of Rust is needed because Dora uses some unstable features of Rust (e.g. inline assembly).
Dora uses cargo for building, which is bundled with Rust:
# install last nightly and use it for this project
rustup update nightly
rustup override set nightly
# run all tests in debug and release mode
LLVM_SYS_50_PREFIX=$LLVM_INSTALL_DIR ./test
LLVM_SYS_50_PREFIX=$LLVM_INSTALL_DIR ./test-release