GNOME Bugzilla – Bug 680777
Update for bindings
Last modified: 2014-02-25 22:27:49 UTC
Using gst-rtsp-server from git and trying to use the generated GIR with Vala results in the following error: GstRtspServer-1.0.gir:549.7-549.25: warning: Signal `Gst.RTSPMedia.new_state' conflicts with method of the same name <virtual-method name="new_state"> ^^^^^^^^^^^^^^^^^^^
Out of curiosity, why has this not been a problem before. Both have been there since 2010 afaict, so hard to change now. Also, why is it not a problem for e.g. GtkButton's "clicked" signal and clicked vfunc and gst_button_clicked() ?
Having a closer look at https://live.gnome.org/Vala/UpstreamGuide, it says that you have to resolve such issues in the .metadata file. In order to generate a new VAPI for gst-rtsp-server the Vala bindings of its dependencies have to be created first. I couldn't find bindings for gstreamer-1.0, at least they are not part of Vala (as are the 0.10 bindings).
(In reply to comment #1) > Out of curiosity, why has this not been a problem before. Both have been there > since 2010 afaict, so hard to change now. > The Vala bindings haven't been updated for ~2 years and never where based on the GIR file, that's what I want to change.
For what it's worth, someone else was also working on creating Vala bindings for GStreamer based on the g-i info Don't remember the name right now, but you could ask on IRC.
Created attachment 225823 [details] [review] Fixed comments and GIR annotations
Created attachment 225824 [details] [review] Add boxed types to allow access from bindings
Created attachment 225825 [details] [review] Rename find_media to find_factory
Created attachment 225826 [details] [review] Update Vala bindings
The patches add support for Vala bindings based on the GIR file and gstreamer 1.0. I had to do some changes to the API in order to get proper bindings. This should be helpful for pygobject bindings, too. It's still work in progress as the copy functions of the newly added boxed types are only placeholders! Patches are also available at https://github.com/sebp/gst-rtsp-server/tree/vala
Does not seem to want to compile: .... libtoolize: Remember to add `LT_INIT' to configure.ac. + running aclocal -I m4 -I common/m4 ... + running autoheader ... + running autoconf ... + running automake --add-missing --copy... bindings/vala/Makefile.am:1: ENABLE_VAPIGEN does not appear in AM_CONDITIONAL
You are probably missing vapigen.m4 which is available from http://git.gnome.org/browse/vala/tree/vapigen/vapigen.m4
I have this file: /usr/share/vala-0.18/vapigen.m4 Am I supposed to copy it into our common directory?
More like gst-rtsp-server/m4/ But I think the vala bindings should be removed from the gst-rtsp-server module altogether and be maintained externally as part of vala or g-i or whatever, just like we do for all other modules.
I would be fine maintaining the Vala bindings outside, the annotation and boxed type changes are necessary nevertheless, though.
Pushed two of these patches. About the boxed types for GstRTSPSessionStream, GstRTSPSessionMedia, and GstRTSPMediaStream: maybe those should just be made refcounted ? (and/or turned into mini objects?). Wim? commit 5cec59737ba163409176af4a5e910aae177c8938 Author: Sebastian Pölsterl <sebp@k-d-w.org> Date: Mon Oct 1 20:03:43 2012 +0200 rtsp-media-mapping: rename find_media vfunc to find_factory The virtual method and class method should have the same name so it is correctly represented in GIR file https://bugzilla.gnome.org/show_bug.cgi?id=680777 commit e11e855ac8b3b3b90fc410631a0608050c4453e8 Author: Sebastian Pölsterl <sebp@k-d-w.org> Date: Mon Oct 1 19:46:15 2012 +0200 rtsp-server: fixed comments and GIR annotations https://bugzilla.gnome.org/show_bug.cgi?id=680777
Marking as blocker, since this is ABI relevant (if we want to make it a mini object).
Comment on attachment 225826 [details] [review] Update Vala bindings Let's reunite the gst-rtsp-server vala bindings with the rest of the GStreamer vala bindings family :)
Created attachment 227456 [details] [review] Add additional annotations Due to refactoring by Wim in master, defining boxed types is no longer necessary, I updated a couple of annotations, though. I'm going to get the vala bindings accepted vala now.
Great, thanks! I guess we can close this then (if not, re-open please). commit 75598337a90ad7dd390e81063d62c464e52ec56e Author: Sebastian Pölsterl <sebp@k-d-w.org> Date: Sun Oct 28 13:48:44 2012 +0100 rtsp-server: added annotations to indicate type of ownership transfer of return values https://bugzilla.gnome.org/show_bug.cgi?id=680777 commit 09718e294dd423b3a46a43f740ccad01b6f96997 Author: Tim-Philipp Müller <tim@centricular.net> Date: Sun Oct 28 15:09:04 2012 +0000 bindings: remove vala bindings They'll be reunited with the other GStreamer bindings https://bugzilla.gnome.org/show_bug.cgi?id=680777