Re: [Vala] gnome-db - binding problems



On Tue, 2009-01-20 at 13:55 +0100, Frederik wrote:
I am trying to bind libgda-3.0 (generation base attached to this mail).
I have already worked around some naming conflicts via metadata. But for
one thing I have no solution:

Cool!

In 'libgda/gda-data-model.h' there is this enum:

typedef enum {
  GDA_DATA_MODEL_ACCESS_RANDOM = 1 << 0,
  GDA_DATA_MODEL_ACCESS_CURSOR_FORWARD = 1 << 1,
  GDA_DATA_MODEL_ACCESS_CURSOR_BACKWARD = 1 << 2,
  GDA_DATA_MODEL_ACCESS_INSERT  = 1 << 3,
  GDA_DATA_MODEL_ACCESS_UPDATE  = 1 << 4,
  GDA_DATA_MODEL_ACCESS_DELETE  = 1 << 5,
  GDA_DATA_MODEL_ACCESS_WRITE = GDA_DATA_MODEL_ACCESS_INSERT |
GDA_DATA_MODEL_ACCESS_UPDATE |
  GDA_DATA_MODEL_ACCESS_DELETE,
} GdaDataModelAccessFlags;

Now 'vala-gen-introspect' adds ACCESS_DELETE *twice* to the .gi file
because of the line break after the '|' operator.

I can work around that by manually removing the second one for now, but
v-g-i should either be aware of this kind of line break or ignore
duplicates.

I think this was a problem with the v4 build too. glib-mkenums generates
a duplicate registration in the .so

Running vapigen still produces errors:

$ vapigen --library libgda-3.0 libgda-3.0/libgda-3.0.gi
          --vapidir=libgda-3.0

 error: The type name `Xml.Node*' could not be found
 error: The type name `GLib.DateDMY' could not be found

Xml.Node should be found, since I have added 'libxml-2.0' to the .deps
file. What am I doing wrong?

In v4 I had to do:
sed -i 's/xmlNodePtr/xmlNode*/g' libgda-4.0.gi


Hans




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]