From: Patrik Flykt <patrik.flykt@linux.intel.com>
To: linux-bluetooth@vger.kernel.org, connman@lists.01.org
Cc: Grant Erickson <marathon96@gmail.com>
Subject: [PATCH] gdbus: Move typedefs for interwork with strict compilers
Date: Tue, 8 Dec 2015 18:09:02 +0200 [thread overview]
Message-ID: <1449590942-19235-1-git-send-email-patrik.flykt@linux.intel.com> (raw)
From: Grant Erickson <marathon96@gmail.com>
Move enumeration type defintions AFTER the enumerations themselves are declared
and defined such that the header works with strict compilers.
This occurs when building a plugin, compiled with C++, and occurs on all of:
arm-none-linux-gnueabi-g++ (Sourcery G++ Lite 2010q1-202) 4.4.1
arm-poky-linux-gnueabi-g++ (GCC) 4.8.2
g++ (Ubuntu 4.8.4-2ubuntu1~14.04) 4.8.4
---
Hi,
This patch came up on the ConnMan mailing list, applies to Bluez too.
The patch is rebased to latest upstream and commit message amended with
more information.
Cheers,
Patrik
gdbus/gdbus.h | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/gdbus/gdbus.h b/gdbus/gdbus.h
index 9ece4b0..69fbc10 100644
--- a/gdbus/gdbus.h
+++ b/gdbus/gdbus.h
@@ -31,12 +31,6 @@ extern "C" {
#include <dbus/dbus.h>
#include <glib.h>
-typedef enum GDBusMethodFlags GDBusMethodFlags;
-typedef enum GDBusSignalFlags GDBusSignalFlags;
-typedef enum GDBusPropertyFlags GDBusPropertyFlags;
-typedef enum GDBusSecurityFlags GDBusSecurityFlags;
-typedef enum GDbusPropertyChangedFlags GDbusPropertyChangedFlags;
-
typedef struct GDBusArgInfo GDBusArgInfo;
typedef struct GDBusMethodTable GDBusMethodTable;
typedef struct GDBusSignalTable GDBusSignalTable;
@@ -120,6 +114,12 @@ enum GDbusPropertyChangedFlags {
G_DBUS_PROPERTY_CHANGED_FLAG_FLUSH = (1 << 0),
};
+typedef enum GDBusMethodFlags GDBusMethodFlags;
+typedef enum GDBusSignalFlags GDBusSignalFlags;
+typedef enum GDBusPropertyFlags GDBusPropertyFlags;
+typedef enum GDBusSecurityFlags GDBusSecurityFlags;
+typedef enum GDbusPropertyChangedFlags GDbusPropertyChangedFlags;
+
struct GDBusArgInfo {
const char *name;
const char *signature;
--
2.1.4
next reply other threads:[~2015-12-08 16:09 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-08 16:09 Patrik Flykt [this message]
2015-12-09 10:24 ` [PATCH] gdbus: Move typedefs for interwork with strict compilers Johan Hedberg
2015-12-09 19:40 ` Patrik Flykt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1449590942-19235-1-git-send-email-patrik.flykt@linux.intel.com \
--to=patrik.flykt@linux.intel.com \
--cc=connman@lists.01.org \
--cc=linux-bluetooth@vger.kernel.org \
--cc=marathon96@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.