Skip to content

Tracy incompatible with latest capstone #12

@EngineerCharlie

Description

@EngineerCharlie

I've been trying to get tracy working, and have run into numerous difficulties (I think all on my end), however the last hurdle was this:

../../../server/TracyWorker.cpp:3811:25: error: ‘CS_ARCH_ARM64’ was not declared in this scope; did you mean ‘CS_ARCH_ARM’?
 3811 |         rval = cs_open( CS_ARCH_ARM64, CS_MODE_ARM, &handle );
      |                         ^~~~~~~~~~~~~
      |                         CS_ARCH_ARM
../../../server/TracyWorker.cpp:3855:36: error: ‘const struct cs_detail’ has no member named ‘arm64’
 3855 |                         if( detail.arm64.op_count == 1 && detail.arm64.operands[0].type == ARM64_OP_IMM )
      |                                    ^~~~~
../../../server/TracyWorker.cpp:3855:66: error: ‘const struct cs_detail’ has no member named ‘arm64’
 3855 |                         if( detail.arm64.op_count == 1 && detail.arm64.operands[0].type == ARM64_OP_IMM )
      |                                                                  ^~~~~
../../../server/TracyWorker.cpp:3855:92: error: ‘ARM64_OP_IMM’ was not declared in this scope; did you mean ‘ARM_OP_IMM’?
 3855 |                         if( detail.arm64.op_count == 1 && detail.arm64.operands[0].type == ARM64_OP_IMM )
      |                                                                                            ^~~~~~~~~~~~
      |                                                                                            ARM_OP_IMM
../../../server/TracyWorker.cpp:3857:57: error: ‘const struct cs_detail’ has no member named ‘arm64’
 3857 |                             callAddr = (uint64_t)detail.arm64.operands[0].imm;
      |                                                         ^~~~~

Minimal digging showed a few repos having similar issues. The reason is because capstone renamed ARM64 to AArch64 everywhere (see breaking changes in the link below)

https://github.com/capstone-engine/capstone/releases/tag/6.0.0-Alpha1

In the interests of just getting everything running I just used an earlier version of capstone, specifically 5.0.3 (though I think I mistakenly went further back than necessary).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions