BinaryAnalysisPlatform/bap

llvm:symbol-entry errors on llvm 11.0 with x86-64 binaries compiled on windows

matt-j-griffin opened this issue · 1 comments

Attempting to disassemble a windows binary produces the following error:

Failed to build the project: attribute "llvm:symbol-entry" didn't provide a
value for the field "value"

I have previously been using the command bap ./binary.dll -dbir --optimization-level=3 with success in prior versions of bap, though now when I roll back to 2.2.0, 2.3.0 and 2.4.0 I get the same error. This error also occurs with bap specification and bap objdump. I assume this has something to do with the version of LLVM but I am not sure how to change this in BAP?

For reference this is the output of file binary.dll

binary.dll: PE32+ executable (DLL) (GUI) x86-64, for MS Windows

The binary can be disassembled with --loader=raw successfully, but this loses the exported dll symbols.

Invoking bap --llvm-version returns 11.0.1.

This does not occur when I use the docker image so it is probably an issue with my system, I was using debian wsl2. The version of llvm in the container is 9.0.