Work environment
| Questions |
Answers |
| System Capstone runs on OS/arch/bits |
Debian x86_64 |
| Capstone module affected |
All, but RISC-V |
| Source of Capstone |
git clone |
| Version/git commit |
v6.0.0, 08e655c |
Expected behavior
Disabling CAPSTONE_RISCV_SUPPORT from being built shouldn't cause an error.
Actual behavior
Excluding it results in an error due to getSysRegName() in cstool/cstool_riscv.c and suite/cstest/src/test_detail_riscv.c.
Steps to reproduce the behavior
cmake -B build -DCMAKE_BUILD_TYPE=Release -DCAPSTONE_ARCHITECTURE_DEFAULT=0 -DCAPSTONE_X86_SUPPORT=1
cmake --build build -j
Additional Logs, screenshots, source code, configuration dump, ...
CMake error:
/usr/bin/riscv64-linux-gnu-ld.bfd: CMakeFiles/cstool.dir/cstool/cstool_riscv.c.o: in function `print_insn_detail_riscv':
/root/capstone/cstool/cstool_riscv.c:47:(.text+0x170): undefined reference to `getSysRegName'
/usr/bin/riscv64-linux-gnu-ld.bfd: relocation R_RISCV_CALL_PLT against `getSysRegName' which may bind externally can not be used when making a shared object; recompile with -fPIC
Work environment
git cloneExpected behavior
Disabling
CAPSTONE_RISCV_SUPPORTfrom being built shouldn't cause an error.Actual behavior
Excluding it results in an error due to
getSysRegName()in cstool/cstool_riscv.c and suite/cstest/src/test_detail_riscv.c.Steps to reproduce the behavior
Additional Logs, screenshots, source code, configuration dump, ...
CMake error: