psanford / wormhole-william

End-to-end encrypted file transfer. A magic wormhole CLI and API in Go (golang).
MIT License
1.08k stars 55 forks source link

wrong arm format on release v1.0.4 #19

Closed m040601 closed 4 years ago

m040601 commented 4 years ago

I'm trying to run the arm binary you release under the name "arm7" on the raspberry pi 1.2 .

Downloaded from here, https://github.com/psanford/wormhole-william/releases/tag/v1.0.4

$ chmod + ./wormhole-william-linux-arm7 $ ./wormhole-william-linux-arm7

-bash: ./wormhole-william-linux-arm7: cannot execute binary file: Exec format error

$ file wormhole-william-linux-arm7 wormhole-william-linux-arm7: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, Go BuildID=0YIZepyXHTYAuc-8uFmp/jzXcGXEBLXzkuLditY_u/UT2EVchW_bDyh8MKe3ZE/fRE1lMfbIQn6xOdolUqB, not stripped

As you can see this is different from what the vast majority of arm binaries for this platform (should be called "armv7h" ) give. Example, https://github.com/Jguer/yay/releases/tag/v10.0.4

$ file yay_10.0.4_armv7h/yay

yay_10.0.4_armv7h/yay: ELF 32-bit LSB pie executable, ARM, EABI5 version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux-armhf.so.3, BuildID[sha1]=0dcad9ae91e4d262acb63017783c5938ced94e90, for GNU/Linux 3.2.0, stripped

That "x86" shouldnt be there. Maybe something got mixed up in the build process ?

PS: I dont have an arm 64 computer to test run it (Raspberry Pi 4), but I also checked the one you release as "arm64". Should be called "aarch64".

$ file wormhole-william-linux-arm64

wormhole-william-linux-arm64: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, Go BuildID=EFhjyyM10MGZsAiY14oG/kVXqSI1C0fHbXGObwjtk/1GAEHHv7bpwD2U-kOm1Q/q7gQMrO0gj6zdscFn8PP, not stripped

This is how an arm binary for 64bit platform should look like

$ file yay_10.0.4_aarch64/yay

yay_10.0.4_aarch64/yay: ELF 64-bit LSB pie executable, ARM aarch64, version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux-aarch64.so.1, BuildID[sha1]=149f0144183ad856fe2b7192bf1744fd622d032d, for GNU/Linux 3.7.0, stripped

Same thing with the arm5 and arm6

psanford commented 4 years ago

Thanks for reporting this. I believe the issue has been fixed. Can you test again?

m040601 commented 4 years ago

Tested. The binary you release as "wormhole-william-linux-arm7" is now working fine on the armv7h architecture (Raspberry Pi 2)

Thanks for your attention to this issue.