
Hi, I have problem with ghci+cairo on windows. When I try to load, for example like this "ghci -package cairo" it fails with the following error: Loading package random-1.0.0.2 ... linking ... done. Loading package haskell98 ... linking ... done. Loading package syb-0.1.0.2 ... linking ... done. Loading package base-3.0.3.2 ... linking ... done. Loading package mtl-1.1.0.2 ... linking ... done. : C:\Users\alexeys\AppData\Roaming\cabal\cairo-0.12.0\ghc-6.12.3\HScairo-0.12.0.o: unknown symbol `_cairo_surface_destroy' Loading package cairo-0.12.0 ... linking ... : unable to load package `cairo-0.12.0' Even simplest programs don't work in interactive mode, like for example 'Text.hs' that comes with cairo package. However compiled with 'ghc --make' everything works as expected, so its not a "missing dll" problem - everything is in place. I used 'filemon' on "ghci" and in the log I can see that 'libcairo-2.dll' was found and loaded successfully (and this library has '_cairo_surface_destroy' symbol defined). So I don't understand - what more does it want and what can be done to combat it?

Hi Alexey, On 01.02.2011, at 16:47, Alexey Shumitsky wrote:
Hi,
I have problem with ghci+cairo on windows. When I try to load, for example like this "ghci -package cairo" it fails with the following error:
Loading package random-1.0.0.2 ... linking ... done. Loading package haskell98 ... linking ... done. Loading package syb-0.1.0.2 ... linking ... done. Loading package base-3.0.3.2 ... linking ... done. Loading package mtl-1.1.0.2 ... linking ... done. : C:\Users\alexeys\AppData\Roaming\cabal \cairo-0.12.0\ghc-6.12.3\HScairo-0.12.0.o: unknown symbol `_cairo_surface_destroy' Loading package cairo-0.12.0 ... linking ... : unable to load package `cairo-0.12.0'
Even simplest programs don't work in interactive mode, like for example 'Text.hs' that comes with cairo package. However compiled with 'ghc --make' everything works as expected, so its not a "missing dll" problem - everything is in place.
I used 'filemon' on "ghci" and in the log I can see that 'libcairo-2.dll' was found and loaded successfully (and this library has '_cairo_surface_destroy' symbol defined). So I don't understand - what more does it want and what can be done to combat it?
Sorry about the slow feedback. I know that on Windows our Gtk2HsSetup.hs magic file does some name mangling that is necessary because the binary Gtk installer has some oddly named libraries. It might be that we didn't get this mangling right for cairo or that it has changed. I had hoped that somebody with a windows machine might reply to your problems. But maybe you could give us the version of the binary installer. If its new, then they might have changed the naming... Cheers, Axel
_______________________________________________ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

On Thu, Feb 3, 2011 at 9:15 AM, Axel Simon
Hi Alexey,
Sorry about the slow feedback. I know that on Windows our Gtk2HsSetup.hs magic file does some name mangling that is necessary because the binary Gtk installer has some oddly named libraries. It might be that we didn't get this mangling right for cairo or that it has changed. I had hoped that somebody with a windows machine might reply to your problems. But maybe you could give us the version of the binary installer. If its new, then they might have changed the naming...
I took GTK binaries from official site, here: http://www.gtk.org/download-windows.html In particular, cairo libraries are these: http://ftp.gnome.org/pub/gnome/binaries/win32/dependencies/cairo_1.10.2-1_wi... and http://ftp.gnome.org/pub/gnome/binaries/win32/dependencies/cairo-dev_1.10.2-.... Also, I'm using HaskellPlatform-2010.2.0.0.
participants (2)
-
Alexey Shumitsky
-
Axel Simon