I’m trying to get any snap working with Haskell Stack. I created an example I created using
stack new and a basic
snapcraft.yaml but I’m getting an error with
tar when installing Haskell Stack.
Here is the repo: https://github.com/dmp1ce/snapcraft-stack-example
Here is the snapcraft file: https://github.com/dmp1ce/snapcraft-stack-example/blob/master/snap/snapcraft.yaml
Here is the error I’m getting when running
Downloaded ghc-8.6.5. Received ExitFailure (-15) when running Raw command: /bin/tar Jxf /root/.stack/programs/x86_64-linux/ghc-8.6.5.tar.xz Run from: /root/.stack/programs/x86_64-linux/ghc-8.6.5.temp/ Error: Error encountered while unpacking GHC with tar Jxf /root/.stack/programs/x86_64-linux/ghc-8.6.5.tar.xz run in /root/.stack/programs/x86_64-linux/ghc-8.6.5.temp/ The following directories may now contain files, but won't be used by stack: - /root/.stack/programs/x86_64-linux/ghc-8.6.5.temp/ - /root/.stack/programs/x86_64-linux/ghc-8.6.5/ For more information consider rerunning with --verbose flag Unpacking GHC into /root/.stack/programs/x86_64-linux/ghc-8.6.5.temp/ ... Failed to run 'override-build': Exit code was 1. Run the same command again with --debug to shell into the environment if you wish to introspect this failure. An error occurred when trying to execute 'sudo -i env SNAPCRAFT_HAS_TTY=True snapcraft snap' with 'multipass': returned exit code 2.
Any help getting the build to work would be appreciated.
There is also an issue on Github which may be what is causing the error: https://github.com/commercialhaskell/stack/issues/4888