Hi Axel,

Thanks for the timely response. The thing is, my path should have all the necessary variables in its path. It currently looks like this:

D:\workspace\viztool\haskell\lib\extralibs\bin;
D:\workspace\viztool\haskell\bin;
D:\workspace\viztool\haskell\mingw\bin;
D:\workspace\viztool\gtk\bin;
C:\Users\Varnos\AppData\Roaming\cabal\bin

These are all system wide variables. I can, in fact, invoke gtk2hsC2hs.exe from the command line (it tells me to supply the header and binding file etcetera). Might this mean that gtk2hsC2hs itself is asking for a file it is not getting (such as glib)? For now I've reverted to version 2.16 of GTK, but the error persists. I'm loath to get into the cairo error until I've resolved the glib thing.

Regards,
Roeland


2011/2/26 Axel Simon <Axel.Simon@in.tum.de>
Hi Roeland,


On Feb 26, 2011, at 10:34, Loeher Varnos wrote:

Hi,

I am currently in the process of trying to install gtk2hs on my windows 7 machine, but the installation step fails. I did the following:

-installed the latest haskell platform
-added the mingw/bin to path
-Installed gtk 2.16 from the http://www.gtk.org/download.html page, trying both the 2.16 and 2.22 bundles (both give me the same error message)
-added the gtk/bin to path
-ran cabal install gtk2hs-buildtools
-ran cabal install gtk


I think there are issues with 2.22. Try 2.16 for now.


trying to install glib crashes on the following error:

Linking C:\Users\Varnos\AppData\Local\Temp\glib-0.12.02912\glib-0.12.0\dist\setup\setup.exe ...
Configuring glib-0.12.0...
Preprocessing library glib-0.12.0...
gtk2hsC2hs.exe: does not exist

This must be found. You should install the gtk2hs-buildtools first and make sure that gtk2hsC2hs.exe is on your PATH. If you put your ~/.cabal/bin directory onto your PATH using the system preference pane (or whatever it is called) and do a normal cabal install gtk2hs-buildtools then this should be all it needs.


cabal: Error: some packages failed to install:
gio-0.12.0 depends on glib-0.12.0 which failed to install.
glib-0.12.0 failed during the building phase. The exception was:
ExitFailure 1

trying to install cairo crashes on the following error:

Linking C:\Users\Varnos\AppData\Local\Temp\cairo-0.12.06044\cairo-0.12.0\dist\setup\setup.exe ...
Configuring cairo-0.12.0...
Preprocessing library cairo-0.12.0...
cpp: .\cairo-gtk2hs.h: No such file or directory
cpp: warning: `-x c' after last input file has no effect
cpp: no input files

gtk2hsC2hs, if it is found, will run cpp. But obviously, it should pass gth cairo/cairo.h header file to cpp. This doesn't seem to happen. If this is not a follow-on error, then you can run
cabal configure -v
and check what's being invoked


gtk2hsC2hs.exe: Error during preprocessing
cabal: Error: some packages failed to install:
cairo-0.12.0 failed during the building phase. The exception was:
ExitFailure 1


It might be relevant to note that the gtk2hs-buildtools have been installed, but querying the package with "cabal list gtk2hs-buildtools" returns that the current version of the installation is unknown.

That's ok. gtk2hs-buildtools is not a library but a bunch of applications. So it won't show up as a library which is also the reason (amongst others) that it's not automatically installed when installing gtk2hs.


Any help would be greatly appreciated, I've been stuck on this error for longer than I would like to admit!

Hope this helps,
Axel