mbrubeck / agate

Very simple server for the Gemini hypertext protocol
Apache License 2.0
616 stars 37 forks source link

-bash: ./agate-server.bin: No such file or directory #282

Closed s-nt-s closed 1 year ago

s-nt-s commented 1 year ago

When run agate-server in RPi 3B fails with this message: -bash: ./agate-server.bin: No such file or directory

$ wget -O - $(curl -s https://api.github.com/repos/mbrubeck/agate/releases/latest | grep "browser_download_url.*agate.armv7-unknown-linux.*.gz" | cut -d'"' -f4) | gunzip > agate-server.bin
--2023-08-10 19:27:55--  https://github.com/mbrubeck/agate/releases/download/v3.3.1/agate.armv7-unknown-linux-gnueabihf.gz
Resolving github.com (github.com)... 140.82.121.3
Connecting to github.com (github.com)|140.82.121.3|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://objects.githubusercontent.com/github-production-release-asset-2e65be/264589205/d22b6b5d-0770-48d1-98d3-50eb4598df4a?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20230810%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20230810T172755Z&X-Amz-Expires=300&X-Amz-Signature=b15cc2bc6640cdc8e99210aef5d58a2d7b284c645b8f0f9c832dd5e26a1982d0&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=264589205&response-content-disposition=attachment%3B%20filename%3Dagate.armv7-unknown-linux-gnueabihf.gz&response-content-type=application%2Foctet-stream [following]
--2023-08-10 19:27:55--  https://objects.githubusercontent.com/github-production-release-asset-2e65be/264589205/d22b6b5d-0770-48d1-98d3-50eb4598df4a?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20230810%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20230810T172755Z&X-Amz-Expires=300&X-Amz-Signature=b15cc2bc6640cdc8e99210aef5d58a2d7b284c645b8f0f9c832dd5e26a1982d0&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=264589205&response-content-disposition=attachment%3B%20filename%3Dagate.armv7-unknown-linux-gnueabihf.gz&response-content-type=application%2Foctet-stream
Resolving objects.githubusercontent.com (objects.githubusercontent.com)... 185.199.111.133, 185.199.108.133, 185.199.110.133, ...
Connecting to objects.githubusercontent.com (objects.githubusercontent.com)|185.199.111.133|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 895767 (875K) [application/octet-stream]
Saving to: ‘STDOUT’

-                                         100%[=====================================================================================>] 874.77K  4.87MB/s    in 0.2s    

2023-08-10 19:27:56 (4.87 MB/s) - written to stdout [895767/895767]

$ chmod +x agate-server.bin 
$ ./agate-server.bin 
-bash: ./agate-server.bin: No such file or directory

My environment info:

$ cat /etc/os-release
PRETTY_NAME="Debian GNU/Linux 11 (bullseye)"
NAME="Debian GNU/Linux"
VERSION_ID="11"
VERSION="11 (bullseye)"
VERSION_CODENAME=bullseye
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"

$ cat /proc/cpuinfo
processor   : 0
BogoMIPS    : 38.40
Features    : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part    : 0xd03
CPU revision    : 4

processor   : 1
BogoMIPS    : 38.40
Features    : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part    : 0xd03
CPU revision    : 4

processor   : 2
BogoMIPS    : 38.40
Features    : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part    : 0xd03
CPU revision    : 4

processor   : 3
BogoMIPS    : 38.40
Features    : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part    : 0xd03
CPU revision    : 4

Hardware    : BCM2835
Revision    : a02082
Serial      : 0000000053bb7581
Model       : Raspberry Pi 3 Model B Rev 1.2
Johann150 commented 1 year ago

I'm not sure which CPU architecture the Raspberry Pi 3 Model B has, but from having a quick look it seems it has ARMv8 not ARMv7. Can you try the arm-unknown-linux-gnueabihf variant instead? (Or if that doesn't work, maybe try aarch64-unknown-linux-gnu too.)

s-nt-s commented 1 year ago
$ wget -q -O - $(curl -s https://api.github.com/repos/mbrubeck/agate/releases/latest | grep "browser_download_url.*aarch64-unknown-linux-gnu.*.gz" | cut -d'"' -f4) | gunzip > agate-server.bin
chmod +x agate-server.bin
$ ./agate-server.bin --version
agate 3.3.1

works, thanks. But I was completely sure that I have used agate.armv7-unknown-linux in RPi3 some time ago without problem @_@