csweichel/lama

Download script fails to support aarch64 architecture for Android devices

Opened this issue · 1 comments

Hi,
I encountered this issue while trying to download your http server on my Android device with the aarch64 architecture. I noticed that the download script assumes that all possible values of uname -s + "_" + uname -m have binaries in your GitHub release. However, I found that this assumption is not valid as your release page only has arm64 binaries for Android and other operating systems.

I also noticed that the script assumes that Android architecture is arm64, but my device's architecture is aarch64.
As a result, the script failed to download the server binary and gave me an error message.

To reproduce the error, I ran the following command:

curl -fsSL https://lama.sh | sh -x

And here's the error message I received:

curl: (2) no URL specified!
curl: try 'curl --help' for more information

I was able to download the arm64 binary manually and run it on my device using the UserLand application, but I wanted to bring this issue to your attention so that you can update your download script to support the aarch64 architecture for Android devices.

Thank you for your attention to this matter.
Peace 🕊️

A quick fix is changing :

export platform="$(uname -s)_$(uname -m)"

With

- export platform="$(uname -s)_$(uname -m)"
+ export platform="$(uname -s)_$(uname -m | sed -ure 's~aarch64~arm64~')"