Installing Haskell on Windows, cabal config

2020-02-14 06:47发布

问题:

I'm installing Haskell on Windows based on the instructions at https://www.haskell.org/platform/ and looking at step 3, it says, Modify your cabal config file (you can verify the location by running "cabal user-config init") to contain the following lines:

extra-prog-path: C:\Program Files\Haskell Platform\8.0.2\msys\usr\bin
extra-lib-dirs: C:\Program Files\Haskell Platform\8.0.2\mingw\lib
extra-include-dirs: C:\Program Files\Haskell Platform\8.0.2\mingw\include

But the auto generated config file contains e.g.

extra-prog-path: C:\Users\w\AppData\Roaming\cabal\bin

So that's a different value for one of the suggested variables.

Is this intentional?

What should I do, paste the lines from step 3 at the start of the file, the end of the file, overwrite the existing lines or skip step 3 altogether?

回答1:

You don't need to overwrite existing lines. You can have multiple extra-prog-path entries and they all get used.