WASM bindists: wrong unlit path
Summary
When trying to compile .lhs
files, a non-existent unlit
is invoked.
Steps to reproduce
Consider e.g. happy which uses .lhs
:
$ cabal get happy && cd happy-*
$ wasm32-wasi-cabal build
...
wasm32-wasi-ghc-9.7.20230425: could not execute: /nix/store/cm96a9gx16cl6837bvrqw07q6gdw1c96-wasm32-wasi-ghc-gmp/lib/wasm32-wasi-ghc-9.7.20230425/lib/bin/unlit
...
Maybe the issue is that the settings
file contains
("unlit command", "$topdir/bin/unlit")
which is incorrect; the binary is named wasm32-wasi-unlit
.
Expected behavior
It should work, just as it does with a manual -pgmL
flag:
$ wasm32-wasi-cabal build --ghc-options='-pgmL /path/to/lib/wasm32-wasi-ghc-9.7.20230425/bin/wasm32-wasi-unlit'
Environment
- GHC version used: Default from ghc-wasm-meta, commit 5a5c10c3b7e2f9f55bb2f40601cb20c9eb599bb5
- Operating System: NixOS
- System Architecture: x86_64-linux