lib/sign: allow to build with glib version less than 2.44
Ubuntu 14.04 uses glib-2.40 which have no some shiny macroses for interface declaration. Signed-off-by: Denis Pynkin <denis.pynkin@collabora.com>
This commit is contained in:
1 parent
fbd2666e07
commit
485ff7335f
8 files changed
+56
-5
No files matched your search
@@ -33,16 +33,26 @@
|
||||
#include "ostree-remote.h"
|
||||
#include "ostree-types.h"
|
||||
|
||||
/* Special remote */
|
||||
#define OSTREE_SIGN_ALL_REMOTES "__OSTREE_ALL_REMOTES__"
|
||||
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define OSTREE_TYPE_SIGN (ostree_sign_get_type ())
|
||||
|
||||
_OSTREE_PUBLIC
|
||||
GType ostree_sign_get_type (void);
|
||||
|
||||
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
|
||||
typedef struct _OstreeSign OstreeSign;
|
||||
typedef struct _OstreeSignInterface OstreeSignInterface;
|
||||
|
||||
static inline OstreeSign *OSTREE_SIGN (gpointer ptr) { return G_TYPE_CHECK_INSTANCE_CAST (ptr, ostree_sign_get_type (), OstreeSign); }
|
||||
static inline gboolean OSTREE_IS_SIGN (gpointer ptr) { return G_TYPE_CHECK_INSTANCE_TYPE (ptr, ostree_sign_get_type ()); }
|
||||
static inline OstreeSignInterface *OSTREE_SIGN_GET_IFACE (gpointer ptr) { return G_TYPE_INSTANCE_GET_INTERFACE (ptr, ostree_sign_get_type (), OstreeSignInterface); }
|
||||
G_GNUC_END_IGNORE_DEPRECATIONS
|
||||
|
||||
/* Have to use glib-2.44 for this
|
||||
_OSTREE_PUBLIC
|
||||
G_DECLARE_INTERFACE (OstreeSign, ostree_sign, OSTREE, SIGN, GObject)
|
||||
*/
|
||||
|
||||
struct _OstreeSignInterface
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user