Search code examples
debugginghaskellcabalcabal-installhat

How to install `Hat`


I am trying to get the Hat debugger. When I try:

cabal install hat OR cabal install hat -v

At the end I get:

configure: error: in `/tmp/terminfo-0.4.0.0-17745/terminfo-0.4.0.0':
configure: error: curses headers could not be found, so this package cannot be built
See `config.log' for more details
Failed to install terminfo-0.4.0.0
cabal: Error: some packages failed to install:
haskeline-0.7.1.3 depends on terminfo-0.4.0.0 which failed to install.
hat-2.8.0.0 depends on terminfo-0.4.0.0 which failed to install.
terminfo-0.4.0.0 failed during the configure step. The exception was:
ExitFailure 1

So trouble shooting I try:

cabal install terminfo

And get:

configure: error: in `/tmp/terminfo-0.4.0.0-18341/terminfo-0.4.0.0':
configure: error: curses headers could not be found, so this package cannot be built
See `config.log' for more details
Failed to install terminfo-0.4.0.0
cabal: Error: some packages failed to install:
terminfo-0.4.0.0 failed during the configure step. The exception was:
ExitFailure 1

What do I do to install Hat?


Solution

  • Assuming you're on a Linux of some sort, there should be a system package like "libncurses5-dev" (that's the name in Ubuntu) that you can install to get the curses headers.