Closed issue by ackalker on void-packages repository https://github.com/void-linux/void-packages/issues/11481 Description: ### System * xuname: Void 4.19.38_1 x86_64 GenuineIntel uptodate rrrrmdFFFFFFFF * package: stack-1.9.3_1 ### Expected behavior `stack setup` should complete without errors. ### Actual behavior (while trying to build ltcmelo/psychec) ``` $ stack setup Downloaded lts-5.1 build plan. Preparing to install GHC to an isolated location. This will not interfere with any system-level installation. Downloaded ghc-7.10.3. Installed GHC. The GHC located at /home/miki/.stack/programs/x86_64-linux/ghc-7.10.3/bin/ghc failed to compile a sanity check. Please see: http://docs.haskellstack.org/en/stable/install_and_upgrade/ for more information. Exception was: Received ExitFailure 1 when running Raw command: /home/miki/.stack/programs/x86_64-linux/ghc-7.10.3/bin/ghc /tmp/stack-sanity-check-03904f76efe7d887/Main.hs -no-user-package-db Run from: /tmp/stack-sanity-check-03904f76efe7d887/ Standard output: [1 of 1] Compiling Main ( /tmp/stack-sanity-check-03904f76efe7d887/Main.hs, /tmp/stack-sanity-check-03904f76efe7d887/Main.o ) Linking /tmp/stack-sanity-check-03904f76efe7d887/Main ... Standard error: /bin/ld: cannot find -lgmp collect2: error: ld returned 1 exit status ``` ### Steps to reproduce the behavior * Run `stack setup` for the first time in a clean environment (i.e. no `$HOME/.stack` directory. ### Steps to fix the problem * Install `gmp-devel` package. I believe the `gmp-devel` package should be added to `stack` as a runtime dependency for `stack` to be usable "out of the box". See also: commercialhaskell/stack#4034 .