Edit the .cabal stack new file and add mtl to the build-depends section. This part of the file should look like this:
build-depends: base >= 4.7 && < 5 , mtl
Then do a stack build to stack ghci .
By the way, do not use stack install to install libraries - this is just a shortcut for copying binary files. For instance. stack install hlint first build the package and then copy the resulting binary to ~ / .local / bin /. Instead, always add packages to the .cabal file, as shown above, and use stack build to have them installed.
source share