0

trying to install BlogLiterately on win7/64.

  • installed HP 2014.2/64
  • cabal update
  • cabal install cabal-install
  • renamed C:\Program Files\Haskell Platform\2014.2.0.0\lib\extralibs\bin\cabal.exe to *.old
  • cabal update
  • cabal install BlogLiterately fails cuz needs unix toolchain to install new version of network
  • tried installing mingw, but gave up cuz the package manager that pops up only lists packages with suffix 32, i want 64, can't tell from http://www.mingw.org/ if it supports 64 bit.
  • tried installing cygwin64, added C:\cygwin64\bin to the end of PATH, didn't work, see on internet that people think cygwin doesn't work for ghc so well anymore, even though the original error said cygwin would work
  • found http://msys2.github.io/, installed it, followed instructions to update with pacman on that page, used Win64 Shell
  • got error that HsOpenSSL is missing c libs eay32 ssl32, googling says to install http://slproweb.com/products/Win32OpenSSL.html then cabal install HsOpenSSL --extra-include-dirs="c:/OpenSSL-Win64/include" --extra-lib-dirs="c:/OpenSSL-Win64" -- this works, but can't find any official looking docs saying i need Win32OpenSSL -- why can't cabal install this for me?
  • now cabal install BlogLiterately fails cuz ghc.exe: unable to load package 'hs-bibutils-5.5'

the error:

ghc.exe: warning: _stricmp from msvcrt is linked instead of __imp__stricmp
ghc.exe: warning: _stricmp from msvcrt is linked instead of __imp__stricmp
ghc.exe: warning: _atoi64 from msvcrt is linked instead of __imp__atoi64
ghc.exe: warning: toupper from msvcrt is linked instead of __imp_toupper
ghc.exe: warning: _strnicmp from msvcrt is linked instead of __imp__strnicmp
ghc.exe: C:\Users\nlab\AppData\Roaming\cabal\x86_64-windows-ghc-7.8.3\hs-bibutils-5.5\HShs-bibutils-5.5.o: unknown symbol `strdup'

cabal install hs-bibutils --reinstall --force-reinstalls succeeds, but i get the same error when retrying the BlogLiterately install. i tried moving /c/Program Files/Haskell Platform/2014.2.0.0/mingw/bin to the front of the PATH and again reinstalling hs-bibutils, same result.

what is the right way to do this?!?! which unix toolchain are we supposed to use, and how are we supposed to configure it? why isn't it enough that HP includes mingw's binaries? gah.

user1441998
  • 459
  • 4
  • 14
  • 1
    So far [minghc](https://github.com/fpco/minghc) worked for me without issues. – András Kovács Jun 19 '15 at 06:55
  • so is HP no longer the way to go on windows? all the HP libraries are easily cabal installed on minghc? – user1441998 Jun 19 '15 at 07:05
  • The `network` library is primary designed for \*nix and is known to have problems in Windows environment, one of the main reasons of Haskell Platform for Windows (as I heard). Neil Mitchell, Michael Snoyberg and contributors were "tired" of the Haskell Platform cycle and went for the [minghc](https://github.com/fpco/minghc), which has as one of the advantages to deal with `network`. Hence, it is highly recommend to try `minghc`, although it isn't the *official* way (yet). – Guiraldelli Jun 19 '15 at 16:52
  • well after dealing with https://github.com/haskell/cabal/issues/2502 / https://github.com/haskell/cabal/issues/2525, minghc gave the exact same error for `hs-bibutils` :( can any of you guys install hs-bibutils on 64 bit windows? – user1441998 Jun 20 '15 at 03:40
  • seems to be this? https://ghc.haskell.org/trac/ghc/ticket/9215 – user1441998 Jun 20 '15 at 03:51
  • well 32 bit worked, after failing to be able to install the latest HaXml, i randomly figured out i could install HaXml-1.23.3. gah – user1441998 Jun 20 '15 at 04:39

1 Answers1

0

For posterity, new versions of the Haskell Platform for windows (since 8.0.1) allow network to build properly if the cabal file is augmented with a few extra settings as described on the platform website: https://www.haskell.org/platform/

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.1\msys\usr\bin
extra-lib-dirs: C:\Program Files\Haskell Platform\8.0.1\mingw\lib
extra-include-dirs: C:\Program Files\Haskell Platform\8.
sclv
  • 38,665
  • 7
  • 99
  • 204