[Haskell-cafe] Re: [darcs-users] workarounds for Codec.Compression.Zlib errors in darcs

Eric Kow kowey at darcs.net
Thu Nov 27 05:49:58 EST 2008


On Wed, Nov 26, 2008 at 14:38:33 +0000, Eric Kow wrote:
> In principle, the same advice applies for Windows users, with more
> details hopefully to follow on how the C libz in a GHC-accesible
> location.  Details to follow.

As promised, here are the details for installing darcs using our
old internal binding to libz on Windows.  Again, the instructions
are either to

  cabal configure -f -external-zlib

(Or to wait for darcs 2.1.2.3 to appear on hackage)

Thanks to Salvatore Insalaco, our Windows Czar!

----------------------------------------------------------------------

There're two zlib versions for Windows: one compiled with ccall
convention, and one with stdcall convention. We need the ccall one, at
the address:
http://gnuwin32.sourceforge.net/packages/zlib.htm

The other one will *appear* to work, but darcs will segfault as soon
as the first call to zlib is made.

This is the step-by-step howto:
1) Download the binary from
http://gnuwin32.sourceforge.net/downlinks/zlib-bin-zip.php and unzip
it.
2) Copy the zlib1.dll file in bin directory in ghc's gcc-lib
directory, and then rename it libz.dll.
3a) Copy the zlib1.dll file in c:\windows directory, WITHOUT renaming it.
OR
3b) If you don't want to pollute your windows directory, just copy it
in whatever directory is in the search PATH, or in the one you'll
place darcs.exe binary.

That's all. The cabal install will then just work.
By the way: that's similar to the how-to for making curl work. Maybe
we can update the windows building instructions providing a
"pre-install" instructions to make cabal install darcs just work.

-- 
Eric Kow <http://www.nltg.brighton.ac.uk/home/Eric.Kow>
PGP Key ID: 08AC04F9
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: Digital signature
Url : http://www.haskell.org/pipermail/haskell-cafe/attachments/20081127/0137e1bc/attachment.bin


More information about the Haskell-Cafe mailing list