After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 693865 - Add Vala bindings
Add Vala bindings
Status: RESOLVED FIXED
Product: libgdata
Classification: Platform
Component: General
git master
Other Linux
: Normal enhancement
: ---
Assigned To: libgdata-maint
libgdata-maint
Depends on:
Blocks:
 
 
Reported: 2013-02-15 08:46 UTC by Evan Nemerson
Modified: 2013-02-24 09:17 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Add Vala bindings. (6.39 KB, patch)
2013-02-15 08:46 UTC, Evan Nemerson
needs-work Details | Review
Add Vala bindings (6.25 KB, patch)
2013-02-22 07:03 UTC, Evan Nemerson
committed Details | Review

Description Evan Nemerson 2013-02-15 08:46:17 UTC
Created attachment 236223 [details] [review]
Add Vala bindings.

I'm trying to move Vala bindings out of Vala and into the libraries they bind (for the reasons mentioned at [1]) for libraries which are willing to ship them.  A patch to do this for libgdata is attached.

I don't mind helping with the maintenance, just CC me on bug reports (or assign them to me), poke me on IRC, etc.

[1] https://live.gnome.org/Vala/UpstreamGuide#Why_Distribute_Bindings_Upstream
Comment 1 Philip Withnall 2013-02-16 12:46:13 UTC
Review of attachment 236223 [details] [review]:

::: Makefile.am
@@ +516,3 @@
+-include $(VAPIGEN_MAKEFILE)
+
+gdata/libgdata.vapi: gdata/GData-@GDATA_API_VERSION_MAJOR@.@GDATA_API_VERSION_MINOR@.gir gdata/GData-@GDATA_API_VERSION_MAJOR@.@GDATA_API_VERSION_MINOR@.metadata

I think it would make sense to include the GData API version in the .vapi file name, the same as it is included in the .gir file name.

@@ +650,3 @@
 MAINTAINERCLEANFILES += ChangeLog
 
+GITIGNOREFILES = \*.o \*.lo

What’s this for?
Comment 2 Evan Nemerson 2013-02-22 07:03:48 UTC
Created attachment 237142 [details] [review]
Add Vala bindings

(In reply to comment #1)
> Review of attachment 236223 [details] [review]:
> 
> ::: Makefile.am
> @@ +516,3 @@
> +-include $(VAPIGEN_MAKEFILE)
> +
> +gdata/libgdata.vapi:
> gdata/GData-@GDATA_API_VERSION_MAJOR@.@GDATA_API_VERSION_MINOR@.gir
> gdata/GData-@GDATA_API_VERSION_MAJOR@.@GDATA_API_VERSION_MINOR@.metadata
> 
> I think it would make sense to include the GData API version in the .vapi file
> name, the same as it is included in the .gir file name.

So do I, but VAPI names are supposed to match pkg-config names (that is how we determine which cflags and libs to pass along to the cc), not GIR names.  libgdata's pkg-config file is libgdata.pc.

> @@ +650,3 @@
>  MAINTAINERCLEANFILES += ChangeLog
> 
> +GITIGNOREFILES = \*.o \*.lo
> 
> What’s this for?

Oops, left over from when I was trying to fix .gitignore, but I can't find a way to make git.mk work with non-recursive builds without modifying it.  It's off-topic for this bug.
Comment 3 Philip Withnall 2013-02-23 00:41:18 UTC
Review of attachment 237142 [details] [review]:

(In reply to comment #2)
> Created an attachment (id=237142) [details] [review]
> Add Vala bindings
> 
> (In reply to comment #1)
> > Review of attachment 236223 [details] [review] [details]:
> > 
> > ::: Makefile.am
> > @@ +516,3 @@
> > +-include $(VAPIGEN_MAKEFILE)
> > +
> > +gdata/libgdata.vapi:
> > gdata/GData-@GDATA_API_VERSION_MAJOR@.@GDATA_API_VERSION_MINOR@.gir
> > gdata/GData-@GDATA_API_VERSION_MAJOR@.@GDATA_API_VERSION_MINOR@.metadata
> > 
> > I think it would make sense to include the GData API version in the .vapi file
> > name, the same as it is included in the .gir file name.
> 
> So do I, but VAPI names are supposed to match pkg-config names (that is how we
> determine which cflags and libs to pass along to the cc), not GIR names. 
> libgdata's pkg-config file is libgdata.pc.

Fair enough. Could you add a comment to the Makefile to make this clear please? Then if libgdata breaks API, I’ll be reminded to change the .pc file name in sync with the .vapi file name.
With that change, please commit straight to master. Thanks!

> > @@ +650,3 @@
> >  MAINTAINERCLEANFILES += ChangeLog
> > 
> > +GITIGNOREFILES = \*.o \*.lo
> > 
> > What’s this for?
> 
> Oops, left over from when I was trying to fix .gitignore, but I can't find a
> way to make git.mk work with non-recursive builds without modifying it.  It's
> off-topic for this bug.

Yeah it’s annoying. I’ve never found time to dig into it and fix git.mk though. :-(
Comment 4 Philip Withnall 2013-02-24 09:16:43 UTC
Committed with that change.

commit 2186969875520d535704f61280f62145932b4948
Author: Evan Nemerson <evan@coeus-group.com>
Date:   Thu Feb 21 21:53:45 2013 -0800

    build: Add Vala bindings
    
    Closes: https://bugzilla.gnome.org/show_bug.cgi?id=693865

 Makefile.am              |  27 +++++++++++++
 configure.ac             |   2 +
 gdata/GData-0.0.metadata |  11 ++++++
 m4/vapigen.m4            | 101 +++++++++++++++++++++++++++++++++++++++++++++++
 4 files changed, 141 insertions(+)