ghidra icon indicating copy to clipboard operation
ghidra copied to clipboard

the protoc 3.17.3 binary file doesn't match current M1 machine

Open lemuellew opened this issue 2 years ago • 5 comments

Describe the bug buildGhidra error due to wrong protoc format

To Reproduce Steps to reproduce the behavior:

* What went wrong:
Execution failed for task ':Debugger-gadp:generateProto'.
> A problem occurred starting process 'command '/Users/xxxx/.gradle/caches/modules-2/files-2.1/com.google.protobuf/protoc/3.17.3/53db7dd118d8dfc87d48f8a31a816bcdee6f0f5d/protoc-3.17.3-osx-aarch_64.exe''
❯ uname -m
arm64
/Users/xxxx/.gradle/caches/modules-2/files-2.1/com.google.protobuf/protoc/3.17.3/53db7dd118d8dfc87d48f8a31a816bcdee6f0f5d/protoc-3.17.3-osx-aarch_64.exe: Mach-O 64-bit executable x86_64

The protoc release page provider aarch64 since 3.20.0

Environment (please complete the following information):

  • OS: macOS 10.15.1 Apple silicon
  • Java Version: 17
  • Ghidra Version: GitHub master
  • Ghidra Origin: locally built

lemuellew avatar Aug 21 '22 08:08 lemuellew

Do you not have Rosetta installed?

ryanmkurtz avatar Aug 21 '22 08:08 ryanmkurtz

Yes, I don't install Rosetta and I know this can be solved with Rosetta. I mean the file name is confusing.

lemuellew avatar Aug 21 '22 09:08 lemuellew

Yea, I guess they assumed everyone would have Rosetta so they just copied/renamed the x64 file and called it aarch64. We plan on upgrading to the latest before releasing 10.2 though, so it will get fixed.

ryanmkurtz avatar Aug 21 '22 09:08 ryanmkurtz

Related to #4415

ryanmkurtz avatar Aug 21 '22 09:08 ryanmkurtz

Yes, I think just upgrade to a newer version(like 3.21.5) will be ok. https://search.maven.org/artifact/com.google.protobuf/protoc/3.21.5/pom

❯ file protoc-*
protoc-21.0-rc-1-osx-aarch_64.exe: Mach-O 64-bit executable x86_64
protoc-3.17.3-osx-aarch_64.exe:    Mach-O 64-bit executable x86_64
protoc-3.20.0-osx-aarch_64.exe:    Mach-O 64-bit executable x86_64
protoc-3.21.4-osx-aarch_64.exe:    Mach-O 64-bit executable arm64
protoc-3.21.5-osx-aarch_64.exe:    Mach-O 64-bit executable arm64

lemuellew avatar Aug 21 '22 09:08 lemuellew