haskell / docker-haskell

MIT License
63 stars 37 forks source link

arm64 does not include stack #59

Closed AlistairB closed 1 year ago

AlistairB commented 2 years ago

Stack has had patchy support of arm64 in the past, but it is not officially supported.

The last released binary is for stack 2.7.1, however I get this failure on debian buster.

There are unofficial binaries that ghcup uses, but I don't think official images should include anything unofficial.

vic1707 commented 2 years ago

Stack has had patchy support of arm64 in the past, but it is not officially supported.

The last released binary is for stack 2.7.1, however I get this failure on debian buster.

There are unofficial binaries that ghcup uses, but I don't think official images should include anything unofficial.

I have the same problem, did you find a workaround? Maybe another image that works with both ARM64 and AMD64?

AlistairB commented 2 years ago

I think the only workaround currently is to use an image based on ghcup, as ghcup includes unofficial ARM64 binaries for stack that I assume work.

I have poked the stack folk about fixing ARM64 support and there was some interest, but no movement as of yet.

sanderjo commented 2 years ago

Same here on my ARM / aarch64:

sander@nanopineo2:~$ docker run -it haskell:latest /bin/bash
root@04f4e5aea8f2:/# uname -a
Linux 04f4e5aea8f2 5.10.60-sunxi64 #21.08.1 SMP Wed Aug 25 18:29:57 UTC 2021 aarch64 GNU/Linux
root@04f4e5aea8f2:/# stack
bash: stack: command not found
root@04f4e5aea8f2:/#

A solution would be nice.

AlistairB commented 2 years ago

Unfortunately this will need to be fixed upstream. The last stack release to include ARM64 binaries was 2.7.1 and they don't appear to work in debian buster.

The only work around for now is to use the ghcup unofficial binaries. You can install ghcup in a docker image and install stack this way. Unofficial binaries are not appropriate for official docker images though so can't take that approach here.

AlistairB commented 2 years ago

Stack is producing aarch64 binaries again, but they still do not work on debian buster.

AlistairB commented 1 year ago

This has been resolved

benz0li commented 1 year ago

@AlistairB FYI https://github.com/commercialhaskell/stack/issues/6142