Re: gdk_pixbuf_mlsource requires X

Jacques Garrigue <[email protected]> Fri, 25 Jun 2010 14:55:41 +0900 (JST)
Newsgroups gmane.comp.lang.ocaml.lib.gtk
Message-ID <[email protected]>
From: Richard Jones <[email protected]>

> I just want to point this out ...
> 
>   $ gdk_pixbuf_mlsource --build-list static Throbber.png animation Throbber.gif > /dev/null
> 
> vs
> 
>   $ DISPLAY= gdk_pixbuf_mlsource --build-list static Throbber.png animation Throbber.gif > /dev/null
>   Fatal error: exception Gtk.Error("GtkMain.init: initialization failed
>   ml_gtk_init: initialization failed")
> 
> Actually I'm not using quite the latest version of lablgtk2 and I
> haven't checked if this is still a problem with the latest upstream.
> If it is, then this is going to make it a little bit harder to build
> my project on the Fedora autobuilders, where X is obviously not
> available.  (I'll have to bundle the *.ml file instead)

Good point: there is no reason to link gtkMain.cmo, as
Gobject.Type.init is sufficient.

This is now fixed in subversion, and will go in the next release.

     Jacques