mirror of
https://github.com/radareorg/radare2.git
synced 2025-03-02 03:05:40 +00:00
Build arch detection for RISC-V (#13560)
Make sure that `asm.arch` and `anal.arch` is set correctly when starting radare on RISC-V.
This commit is contained in:
parent
726e15054c
commit
8aa8782aa2
@ -491,6 +491,14 @@ static inline void *r_new_copy(int size, void *data) {
|
||||
/* we should default to wasm when ready */
|
||||
#define R_SYS_ARCH "x86"
|
||||
#define R_SYS_BITS R_SYS_BITS_32
|
||||
#elif __riscv__ || __riscv
|
||||
# define R_SYS_ARCH "riscv"
|
||||
# define R_SYS_ENDIAN 0
|
||||
# if __riscv_xlen == 32
|
||||
# define R_SYS_BITS R_SYS_BITS_32
|
||||
# else
|
||||
# define R_SYS_BITS (R_SYS_BITS_32 | R_SYS_BITS_64)
|
||||
# endif
|
||||
#else
|
||||
#ifdef _MSC_VER
|
||||
#ifdef _WIN64
|
||||
|
Loading…
x
Reference in New Issue
Block a user