From 01a46e5c652ec8030226a9cf54025e175f56caac Mon Sep 17 00:00:00 2001 From: Emmanuele Bassi Date: Sat, 4 Sep 2010 17:22:39 +0100 Subject: [PATCH] Hack to include glib/gdatasetprivate.h directly The gdatasetprivate.h header includes gatomic.h directly. It all works well in GLib, but inside GObject it will trigger the single inclusion guard. Since this is a private header, and it's kind of a special case, one way to fix it is to declare GLIB_COMPILATION around it and fool the single inclusion guard in gatomic.h into thinking we're compiling GLib and not GObject. --- gobject/gobject.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/gobject/gobject.c b/gobject/gobject.c index f9280c2..1943405 100644 --- a/gobject/gobject.c +++ b/gobject/gobject.c @@ -26,7 +26,12 @@ #include #include +/* fool the single inclusion guard in gatomic.h, which is directly + * included by gdatasetprivate.h + */ +#define GLIB_COMPILATION #include "glib/gdatasetprivate.h" +#undef GLIB_COMPILATION #include "gobject.h" #include "gvaluecollector.h" -- 2.7.4