[Haskell-cafe] Re: Hackage on Linux
Erik de Castro Lopo
mle+hs at mega-nerd.com
Sat Aug 28 21:27:33 EDT 2010
Andrew Coppin wrote:
> On Linux, if I do, say, "cabal install zlib", it falls over and tells me
> it can't find the zlib headers. So I go install them, rerun the command,
> and it works. On Windows, I issue the same command and it falls over and
> says that autoconf doesn't exist. It doesn't even *get* to the part
> where it looks for header files!
You are trying to build code that is designed on and for Linux. As such
it will probably work on all variants of Linux, Mac OSX and a majority
of Unix variants (after installation of the required GNU tools).
Unsurprisingly it does work on windows because windows because windows
does just about everything differently to the Linux and the rest of
the world does it.
> Interestingly, even though everybody claims that it's "impossible" to
> support C bindings on Windows, gtk2hs has managed it somehow. If you try
> to built it, it complains that it can't find the GTK+ headers. Go
> install those, add them to the search path, and suddenly it builds just
> fine. No problems with it. Go figure...
The reason that works is probably because whoever released it had
a windows machine available and took the time to make it work.
In general, code written on and for Linux/Unix is not going compile
with little problem on most Unix-style OSes and close to zero chance
of compiling without siginficant work on windows.
> How about hoping that Linux and Mac devs are going to realise that
> Windows doesn't have some of the problems that people claim it does?
The problems I claim windows has with respect to compiling and
a) No standard place to find C include files.
b) No standard place to find libraries.
c) No standard way to find if common open source libraries are
installed and where.
d) Missing common unix tools like bash. awk, sed, grep, make,
autoconf, automake, libtool, pkg-config etc.
Ideally for installing open source libraries the tools used should be
the same as the ones used on Linux/Unix where they originated.
> My "obviously all desktops are Windows" was not meant to be entirely
> serious. But it's not exactly a revelation to state that Windows has
> much greater penetration in the desktop market than either Linux or
> indeed Mac OS. Linux is much more popular now than it used to be (e.g.,
> I can remember when you had to wear open-toed sandals and eat lentil
> burgers in order to run Linux), but it's not yet anywhere near the level
> of popularity of Windows.
Your assessment is valid for user desktops but highly questionable
for developer desktops.
Erik de Castro Lopo
More information about the Haskell-Cafe