Bug 50712 - Compilation warnings/error because of TP_BASE_CONNECTION_ERROR_IF_NOT_CONNECTED
Summary: Compilation warnings/error because of TP_BASE_CONNECTION_ERROR_IF_NOT_CONNECTED
Status: RESOLVED FIXED
Alias: None
Product: Telepathy
Classification: Unclassified
Component: tp-glib (show other bugs)
Version: git master
Hardware: Other All
: medium normal
Assignee: Telepathy bugs list
QA Contact: Telepathy bugs list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-06-05 01:21 UTC by Guillaume Desmottes
Modified: 2012-06-05 01:56 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Ignore deprecations in TP_BASE_CONNECTION_ERROR_IF_NOT_CONNECTED (1.14 KB, patch)
2012-06-05 01:48 UTC, Guillaume Desmottes
Details | Splinter Review
text-mixin: use versioned deprecation macros (3.93 KB, patch)
2012-06-05 01:48 UTC, Guillaume Desmottes
Details | Splinter Review

Description Guillaume Desmottes 2012-06-05 01:21:30 UTC
I tried building telepathy-logger with tp-glib master. As it still depends on tp-glib 0.18.0 (which is fair) I defined:

AC_DEFINE(TP_VERSION_MIN_REQUIRED, TP_VERSION_0_18, [Ignore post 0.18 deprecations])
AC_DEFINE(TP_VERSION_MAX_ALLOWED, TP_VERSION_0_18, [Prevent post 0.18 APIs])

But still get this error:

contacts-conn.c:687:3: error: 'tp_base_connection_check_connected' is deprecated (declared at /home/cassidy/usr/include/telepathy-1.0/telepathy-glib/base-
connection.h:131): Not available before 0.19 [-Werror=deprecated-declarations]

That's because since 5f90a8dd this function uses tp_base_connection_check_connected() which is annotated with _TP_AVAILABLE_IN_UNRELEASED.
Comment 1 Guillaume Desmottes 2012-06-05 01:48:53 UTC
Created attachment 62561 [details] [review]
Ignore deprecations in TP_BASE_CONNECTION_ERROR_IF_NOT_CONNECTED

This macro is now implemented using in tp_base_connection_check_connected()
which is annotated with _TP_AVAILABLE_IN_UNRELEASED, but we shouldn't raise an
error if app don't want to use 0.20 API yet.
Comment 2 Guillaume Desmottes 2012-06-05 01:48:56 UTC
Created attachment 62562 [details] [review]
text-mixin: use versioned deprecation macros
Comment 3 Xavier Claessens 2012-06-05 01:54:44 UTC
It's a bit ugly for the macro, but I couldn't think about a better solution :(

+1
Comment 4 Guillaume Desmottes 2012-06-05 01:56:46 UTC
Merged to master.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.