mirror of
https://github.com/radareorg/r2sleigh.git
synced 2026-11-07 06:36:00 -10:00
Downloads go by name and pattern, so download-artifact v5's by-id path change does not apply; v8 fails on a digest mismatch, which it should. Co-Authored-By: Claude Opus 5.5 <[email protected]>
1.6 KiB
1.6 KiB
Building r2sleigh
| Dependency | Version | Notes |
|---|---|---|
| Rust | 1.99 | edition 2024, via rustup; rust-toolchain.toml pins it |
| radare2 | 5.9+ | optional; only the differential harnesses run it |
| Z3 | 4.8+ | optional |
Nothing links against libr: no radare2 headers or C compiler are needed.
cargo build --release -p r2s --features sleigh # the shell
cargo build --release -p r2sleigh-cli --features x86 # the Sleigh toolchain
Without --features sleigh the shell builds but refuses to lift.
| Feature | Architectures |
|---|---|
x86 |
x86, x86-64 (16/32/64-bit modes) |
arm |
ARM 32-bit, Thumb, aarch64 |
mips |
MIPS, both endiannesses |
riscv |
RV32GC, RV64GC |
all-archs |
all of the above |
Profiles: release (optimized, parallel codegen, abort on panic, stripped)
for everyday work and CI; dist (LTO, one codegen unit) for distributables;
probe when a profiler must name a line; ci for the equivalence runs.
Tests and gates are in doc/testing.md. Build before
measuring: the harnesses default to target/debug/r2s, which a release build
does not touch.
Troubleshooting
r2s: built without the sleigh feature: rebuild with--features sleigh.- A function refuses where another renders: that is the decompiler printing
only what it can prove.
R2DEC_TRACE_REFUSAL=1names the refusing predicate;pdilprints the lift andpddothe obligations. - Linker errors: only Z3 needs a system library, and only with its
feature on (
apt install libz3-dev,dnf install z3-devel).