On Dec 8, 2009, at 15:43, Andy Stewart wrote:

> Axel Simon <axel.si...@ens.fr> writes:
>
>> Hi Andy,
>>
>> I suspect that you have not added the Makefile rule to create the  
>> Type.chs file. Check the other
>> bindings such as Cairo for an example.  Note that these rules have  
>> changed recently with the
>> multi-threading  fixes.
> In Makefile.am file, it have below snippets:
>
> ------------------------------> snippets start  
> <------------------------------
> ...
> libHSdbus_a_GENERATEDSOURCES =                                \
>       dbus/System/DBus/Types.chs
>
> nodist_libHSdbus_a_SOURCES = $(libHSdbus_a_GENERATEDSOURCES)
>
> libHSdbus_a_SOURCES =                                 \
>       dbus/System/DBus/GConnection.chs                \
>       dbus/System/DBus/GError.chs             \
>       dbus/System/DBus/GMessage.chs           \
>       dbus/System/DBus/GMethod.chs            \
>       dbus/System/DBus/GProxy.chs             \
>       dbus/System/DBus/DBus.hs
>
> htmldoc_HSFILES_HIDDEN += $(libHSdbus_a_GENERATEDSOURCES:.chs=.hs)
>
> libHSdbus_a_LIBADD =  \
>       dbus/System/DBus/DBus_stub.o
>
> dbus/System/DBus/Types.chs :                  \
>       $(srcdir)/tools/hierarchyGen/hierarchy.list \
>       $(srcdir)/tools/hierarchyGen/TypeGenerator$(EXEEXT)  \
>       $(srcdir)/tools/hierarchyGen/Hierarchy.chs.template
>       $(strip $(srcdir)/tools/hierarchyGen/TypeGenerator$(EXEEXT) \
>       $(srcdir)/tools/hierarchyGen/hierarchy.list \
>       $(srcdir)/tools/hierarchyGen/Hierarchy.chs.template \
>       $@ --tag=dbus --lib=dbus --prefix=dbus \
>       --modname=System.DBus.Types --import=*System.Glib.GObject)

The --import=* form is new (in contrast to --import= which does a chs  
import using {# #}). Thus, it seems you're using the recent darcs  
version. So you're all set.

> ...
> ------------------------------> snippets end    
> <------------------------------
>
> And i have wrote
>
>   DBusGProxy                  as GProxy, dbus_g_proxy_get_type if dbus
>
> in `gtk2hs/tools/hierarchyGen/hierarchy.list` file.
>
> Then gtk2hs will generate Types.chs file for type `DBusGProxy`, and  
> below is
> `dbus/System/DBus/Types.chs` file.
>
> <Types.chs>
> So code "{#import System.DBus.Types#}" in GProxy.chs.pp should  
> works fine, because
> Types.chs file generate correctly, right?

Did you do a 'make distclean'? What happens if you do a 'make dbus/ 
System/DBus/Types.chs'?

Axel.


------------------------------------------------------------------------------
Return on Information:
Google Enterprise Search pays you back
Get the facts.
http://p.sf.net/sfu/google-dev2dev
_______________________________________________
Gtk2hs-devel mailing list
Gtk2hs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gtk2hs-devel

Reply via email to