Skip to content
Snippets Groups Projects
Unverified Commit a63b165b authored by aviau's avatar aviau
Browse files

Remove duplicated D-Bus interface files

Now that D-Bus interface files are installed by the Ring daemon,
there is no need to duplicate them in this repository.

This patch introduces a new cmake flag: -DRING_XML_INTERFACES_DIR,
which can be used to specify the directory containing the D-Bus
interface files.

If the flag is not specified, we look for the following directories,
in order:
 - ${RING_BUILD_DIR}/../bin/dbus
   This should work in most cases, where we are building against the
   project directory.

 - ${CMAKE_INSTALL_PREFIX}/share/dbus-1/interfaces
   This is where D-Bus interface files should be installed, as per the
   freedesktop website[1].

1. https://dbus.freedesktop.org/doc/dbus-api-design.html#interface-files

Change-Id: I8e8476c1276a1dbb0af2197a2d2d8efff2724f4e
Tuleap: #688
parent cf8970ac
No related branches found
No related tags found
No related merge requests found
......@@ -204,7 +204,13 @@ INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR}/src)
INCLUDE_DIRECTORIES ( ${CMAKE_CURRENT_BINARY_DIR})
# Build dbus interfaces
SET ( dbus_xml_introspecs_path ${CMAKE_CURRENT_SOURCE_DIR}/xml/)
IF(DEFINED RING_XML_INTERFACES_DIR)
SET (dbus_xml_introspecs_path ${RING_XML_INTERFACES_DIR})
ELSEIF(EXISTS "${RING_BUILD_DIR}/../bin/dbus")
SET (dbus_xml_introspecs_path ${RING_BUILD_DIR}/../bin/dbus)
ELSE()
SET (dbus_xml_introspecs_path ${CMAKE_INSTALL_PREFIX}/share/dbus-1/interfaces)
ENDIF()
#File to compile
SET( libringclient_LIB_SRCS
......@@ -485,7 +491,7 @@ IF(${ENABLE_LIBWRAP} MATCHES true)
# (not necessary in 3.0+)
ELSE()
# presence manager interface
SET ( presencemanager_xml ${dbus_xml_introspecs_path}/presencemanager-introspec.xml )
SET ( presencemanager_xml ${dbus_xml_introspecs_path}/cx.ring.Ring.PresenceManager.xml )
SET( dbus_metatype_path "${CMAKE_CURRENT_SOURCE_DIR}/src/dbus/metatypes.h")
......@@ -503,7 +509,7 @@ ELSE()
)
# configuration manager interface
SET ( configurationmanager_xml ${dbus_xml_introspecs_path}/configurationmanager-introspec.xml )
SET ( configurationmanager_xml ${dbus_xml_introspecs_path}/cx.ring.Ring.ConfigurationManager.xml )
SET_SOURCE_FILES_PROPERTIES(
${configurationmanager_xml}
......@@ -519,7 +525,7 @@ ELSE()
)
# call manager interface
SET ( callmanager_xml ${dbus_xml_introspecs_path}/callmanager-introspec.xml )
SET ( callmanager_xml ${dbus_xml_introspecs_path}/cx.ring.Ring.CallManager.xml )
SET_SOURCE_FILES_PROPERTIES(
${callmanager_xml}
......@@ -535,7 +541,7 @@ ELSE()
)
# video manager interface
SET ( video_xml ${dbus_xml_introspecs_path}/videomanager-introspec.xml )
SET ( video_xml ${dbus_xml_introspecs_path}/cx.ring.Ring.VideoManager.xml )
SET_SOURCE_FILES_PROPERTIES(
${video_xml}
......@@ -552,7 +558,7 @@ ELSE()
# instance interface
SET ( instance_xml ${dbus_xml_introspecs_path}/instance-introspec.xml )
SET ( instance_xml ${dbus_xml_introspecs_path}/cx.ring.Ring.Instance.xml )
SET_SOURCE_FILES_PROPERTIES(
${instance_xml}
......
......@@ -19,6 +19,7 @@ To install the appplication, type the following commands in a console, while in
cmake ..
The following options are often usefull to append to the cmake line:
-DRING_BUILD_DIR=<daemon install location>
-DRING_XML_INTERFACES_DIR=<daemon dbus interface definitions directory>
-DCMAKE_INSTALL_PREFIX=<install location>
-DCMAKE_BUILD_TYPE=<Debug to compile with debug symbols>
-DENABLE_VIDEO=<False to disable video support>
......
This diff is collapsed.
This diff is collapsed.
<?xml version="1.0" ?>
<node name="/instance-introspec" xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0">
<interface name="cx.ring.Ring.Instance">
<tp:docstring xmlns="http://www.w3.org/1999/xhtml">
<p>Count the number of clients actually registered to the core. When initializing your client, you need to register it against the core by using this interface.</p>
</tp:docstring>
<method name="Register" tp:name-for-bindings="Register">
<tp:docstring>
Register a new client to the core. Increments the registration count.
</tp:docstring>
<arg type="i" name="pid" direction="in">
<tp:docstring>
The pid of the client process
</tp:docstring>
</arg>
<arg type="s" name="name" direction="in">
<tp:docstring>
The name of the client
</tp:docstring>
</arg>
</method>
<method name="Unregister" tp:name-for-bindings="Unregister">
<tp:docstring>
Unregister a connected client from the core. Decrements the registration count. If no more clients are connected, ie the registration count equals 0, the core properly quits.
</tp:docstring>
<arg type="i" name="pid" direction="in">
<tp:docstring>
The pid of the client process
</tp:docstring>
</arg>
</method>
<signal name="started" tp:name-for-bindings="started">
<tp:docstring>Notify clients that daemon has started</tp:docstring>
</signal>
</interface>
</node>
<?xml version="1.0" encoding="UTF-8" ?>
<node name="/presencemanager-introspec" xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0">
<interface name="cx.ring.Ring.PresenceManager">
<!-- METHODS !-->
<method name="publish" tp:name-for-bindings="publish">
<tp:added version="1.3.0"/>
<arg type="s" name="accountID" direction="in">
<tp:docstring>
The account from which the presence will be emitted
</tp:docstring>
</arg>
<arg type="b" name="status" direction="in">
<tp:docstring>
Is this account present or not
</tp:docstring>
</arg>
<arg type="s" name="note" direction="in">
<tp:docstring>
A message transmitted by the server to other users
</tp:docstring>
</arg>
</method>
<method name="answerServerRequest" tp:name-for-bindings="answerServerRequest">
<tp:docstring>
Answer a presence request from the server
</tp:docstring>
<tp:added version="1.3.0"/>
<arg type="s" name="uri" direction="in">
<tp:docstring>
</tp:docstring>
</arg>
<arg type="b" name="flag" direction="in">
<tp:docstring>
Is the request granted or denied
</tp:docstring>
</arg>
</method>
<method name="subscribeBuddy" tp:name-for-bindings="subscribeBuddy">
<tp:docstring>
Ask be be notified when 'uri' presence change
</tp:docstring>
<tp:added version="1.3.0"/>
<arg type="s" name="accountID" direction="in">
<tp:docstring>
An account from which get request presence informations
</tp:docstring>
</arg>
<arg type="s" name="uri" direction="in">
<tp:docstring>
A SIP uri to watch
</tp:docstring>
</arg>
<arg type="b" name="flag" direction="in">
<tp:docstring>
</tp:docstring>
</arg>
</method>
<method name="getSubscriptions" tp:name-for-bindings="getSubscriptions">
<tp:added version="1.3.0"/>
<tp:rationale>
New clients connecting to existing daemon need to be aware of active
subscriptions.
</tp:rationale>
<annotation name="org.qtproject.QtDBus.QtTypeName.In0" value="VectorMapStringString">
While there is more status than "Online" or "Offline", only those
</annotation>
<arg type="s" name="accountID" direction="in">
</arg>
<annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="VectorMapStringString"/>
<arg type="aa{ss}" name="credentialInformation" direction="out" tp:type="String_String_Map">
<tp:docstring>
List of hashes map with the following key-value pairs:
* Status: "Online" or "Offline"
* LineStatus: String
</tp:docstring>
</arg>
</method>
<method name="setSubscriptions" tp:name-for-bindings="setSubscriptions">
<tp:added version="1.3.0"/>
<tp:rationale>Calling "subscribeClient" in a loop is too slow</tp:rationale>
<arg type="s" name="accountID" direction="in">
</arg>
<annotation name="org.qtproject.QtDBus.QtTypeName.In1" value="VectorString"/>
<arg type="as" name="uriList" direction="in">
<tp:docstring>
A list of SIP URIs
</tp:docstring>
</arg>
<!--TODO<annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="VectorString"/>
<arg type="as" name="invalidUris" direction="out">
<tp:docstring>
List of invalid URIs. An URI must be a valid SIP URI. Clients should purge
the list from all invalid URIs
</tp:docstring>
</arg>-->
</method>
<!-- SIGNALS !-->
<signal name="newBuddyNotification" tp:name-for-bindings="newBuddyNotification">
<tp:added version="1.3.0"/>
<tp:docstring>
Notify when a registered presence uri presence informations changes
</tp:docstring>
<arg type="s" name="accountID">
<tp:docstring>
The associated account
</tp:docstring>
</arg>
<arg type="s" name="buddyUri">
<tp:docstring>
The registered URI
</tp:docstring>
</arg>
<arg type="b" name="status">
<tp:docstring>
Is the URI present or not
</tp:docstring>
</arg>
<arg type="s" name="lineStatus">
<tp:docstring>
A string containing informations from the user (human readable)
</tp:docstring>
</arg>
</signal>
<signal name="subscriptionStateChanged" tp:name-for-bindings="subscriptionStateChanged">
<tp:added version="1.3.0"/>
<tp:docstring>
Notify when a the server changes the state of a subscription.
</tp:docstring>
<arg type="s" name="accountID">
<tp:docstring>
The associated account
</tp:docstring>
</arg>
<arg type="s" name="buddyUri">
<tp:docstring>
The registered URI
</tp:docstring>
</arg>
<arg type="b" name="state">
<tp:docstring>
True/ false when the subscription is active/termintated.
</tp:docstring>
</arg>
</signal>
<signal name="newServerSubscriptionRequest" tp:name-for-bindings="newServerSubscriptionRequest">
<tp:added version="1.3.0"/>
<arg type="s" name="buddyUri">
<tp:docstring>
Notify when an other user (or the server) request your presence informations
</tp:docstring>
</arg>
</signal>
<signal name="serverError" tp:name-for-bindings="serverError">
<tp:added version="1.3.0"/>
<arg type="s" name="accountID">
<tp:docstring>
Associated account
</tp:docstring>
</arg>
<arg type="s" name="error">
<tp:docstring>
Code returned by the server
</tp:docstring>
</arg>
<arg type="s" name="msg">
<tp:docstring>
Error explain
</tp:docstring>
</arg>
</signal>
</interface>
</node>
<?xml version="1.0" ?>
<node name="/videomanager-introspec" xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0">
<interface name="cx.ring.Ring.VideoManager">
<!-- Video device methods -->
<method name="getDeviceList" tp:name-for-bindings="getDeviceList">
<tp:docstring>Returns a list of the detected v4l2 devices</tp:docstring>
<annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="VectorString"/>
<arg type="as" name="list" direction="out">
</arg>
</method>
<method name="getCapabilities" tp:name-for-bindings="getCapabilities">
<tp:docstring>Returns a map of map of array of strings, containing the capabilities (channel, size, rate) of a device</tp:docstring>
<annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="MapStringMapStringVectorString"/>
<arg type="s" name="name" direction="in">
</arg>
<arg type="a{sa{sas}}" name="cap" direction="out">
</arg>
</method>
<method name="getSettings" tp:name-for-bindings="getSettings">
<tp:docstring>Returns a map of settings for the given device name</tp:docstring>
<annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="MapStringString"/>
<arg type="s" name="device" direction="in">
</arg>
<arg type="a{ss}" name="map" direction="out">
</arg>
</method>
<method name="applySettings" tp:name-for-bindings="applySettings">
<tp:docstring>Set the preferred settings for a given device name</tp:docstring>
<arg type="s" name="name" direction="in">
</arg>
<annotation name="org.qtproject.QtDBus.QtTypeName.In1" value="MapStringString"/>
<arg type="a{ss}" name="settings" direction="in">
</arg>
</method>
<method name="getDefaultDevice" tp:name-for-bindings="getDefaultDevice">
<arg type="s" name="name" direction="out">
</arg>
</method>
<method name="setDefaultDevice" tp:name-for-bindings="setDefaultDevice">
<arg type="s" name="name" direction="in">
</arg>
</method>
<method name="startCamera" tp:name-for-bindings="startCamera">
<tp:docstring> Starts the video camera, which renders the active v4l2 device's video to shared memory. Useful for testing/debugging camera settings</tp:docstring>
</method>
<method name="stopCamera" tp:name-for-bindings="stopCamera">
</method>
<method name="switchInput" tp:name-for-bindings="switchInput">
<arg type="s" name="resource" direction="in">
<tp:docstring>
A media resource locator (MRL).
Currently, the following are supported:
<ul>
<li>camera://DEVICE</li>
<li>display://DISPLAY_NAME[ WIDTHxHEIGHT]</li>
<li>file://IMAGE_PATH</li>
</ul>
</tp:docstring>
</arg>
<arg type="b" name="switched" direction="out">
<tp:docstring>Returns true if the input stream was successfully changed, false otherwise</tp:docstring>
</arg>
</method>
<method name="hasCameraStarted" tp:name-for-bindings="hasCameraStarted">
<annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="Bool"/>
<arg type="b" name="started" direction="out">
<tp:docstring>Returns true if the camera has already started, false otherwise</tp:docstring>
</arg>
</method>
<signal name="deviceEvent" tp:name-for-bindings="deviceEvent">
<tp:docstring>Signal triggered by changes in the detected v4l2 devices, e.g. a camera being unplugged.</tp:docstring>
</signal>
<signal name="startedDecoding" tp:name-for-bindings="startedDecoding">
<tp:docstring>Signal triggered when video is available in a shared memory buffer.</tp:docstring>
<arg type="s" name="id">
<tp:docstring>The ID of the call associated with the video, or "local" in the case of local video</tp:docstring>
</arg>
<arg type="s" name="shmPath">
<tp:docstring>The path of the newly created shared memory</tp:docstring>
</arg>
<arg type="i" name="width">
<tp:docstring>The width of the video in the shared memory</tp:docstring>
</arg>
<arg type="i" name="height">
<tp:docstring>The height of the video in the shared memory</tp:docstring>
</arg>
<arg type="b" name="isMixer">
<tp:docstring>Whether or not this texture belongs to a video mixer or is a single texture</tp:docstring>
</arg>
</signal>
<signal name="stoppedDecoding" tp:name-for-bindings="stoppedDecoding">
<tp:docstring>Signal triggered when video is no longer available in a shared memory buffer.</tp:docstring>
<arg type="s" name="id">
<tp:docstring>The ID of the call associated with the video, or "local" in the case of local video</tp:docstring>
</arg>
<arg type="s" name="shmPath">
<tp:docstring>The path of the newly created shared memory</tp:docstring>
</arg>
<arg type="b" name="isMixer">
<tp:docstring>Whether or not this texture belongs to a video mixer or is a single texture</tp:docstring>
</arg>
</signal>
</interface>
</node>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment