To build snudown with the C2Rust translator and/or cross-checks, initialize the git submodule by running
git submodule update --init path/to/repo.
Make sure to build the
rustc-plugin projects in the
cross-checks folder beforehand.
runtime project must be built with the
libc-hash feature (e.g.
cargo build --features libc-hash).
cd into the
repo directory and run
python setup.py build with one of the following arguments:
--translateto translate the C code to Rust without any checks
--clang-crosschecksto build the C version of snudown with full cross-checking
--rust-crosschecksto translate to cross-checked Rust code
--use-fakechecksmay be appended to use the
fakecheckslibrary to print out the cross-checks, instead of
libclevrbuffrom the MVEE
- running with no flags will build the C version of the code
- Note that
-fmay need to be appended to the end of the command to force a rebuild, if building multiple times consecutively
After building any of the 3 versions, run
python setup.py test to test it.