diff options
author | Murray Cumming <murrayc@murrayc.com> | 2006-06-19 20:43:42 +0000 |
---|---|---|
committer | Murray Cumming <murrayc@src.gnome.org> | 2006-06-19 20:43:42 +0000 |
commit | 76188d3690a992d6a980a9daa5e8e8d5f1442107 (patch) | |
tree | 30181f9f8c0c0a5f94e2460e594fc108278840be | |
parent | a25b66a0e0b4dd78cc5f59f809fe2db79b18ff87 (diff) | |
download | glibmm-76188d3690a992d6a980a9daa5e8e8d5f1442107.tar.gz |
Check whether DestroyNotify is defined, so we can warn about including
2006-06-19 Murray Cumming <murrayc@murrayc.com>
* glib/glibmm/object.h: Check whether DestroyNotify is defined, so we can warn about
including X11/Xlib.h before this header, which will break things.
Bug #316726 from Mert Tugcu and Javeed Shaikh.
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | glib/glibmm/object.h | 6 |
2 files changed, 12 insertions, 0 deletions
@@ -1,3 +1,9 @@ +2006-06-19 Murray Cumming <murrayc@murrayc.com> + + * glib/glibmm/object.h: Check whether DestroyNotify is defined, so we can warn about + including X11/Xlib.h before this header, which will break things. + Bug #316726 from Mert Tugcu and Javeed Shaikh. + 2006-06-09 Cedric Gustin <cedric.gustin@gmail.com> * glib/glibmm/objectbase.h : Inline the set_property and diff --git a/glib/glibmm/object.h b/glib/glibmm/object.h index a1cc756f..60de61a8 100644 --- a/glib/glibmm/object.h +++ b/glib/glibmm/object.h @@ -20,6 +20,12 @@ * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ +//X11 defines DestroyNotify and some other non-prefixed stuff, and it's too late to change that now, +//so let's give people a clue about the compilation errors that they will see: +#ifdef DestroyNotify + #error "X11/Xlib.h seems to have been included before this header. Due to some commonly-named macros in X11/Xlib.h, it may only be included after any glibmm, gdkmm, or gtkmm headers." +#endif //DestroyNotify + #include <glibmm/objectbase.h> #include <glibmm/wrap.h> #include <glibmm/quark.h> |