[cogl] Fix testing of undefined macro constants to check for definedness instead



commit d51c3c423e44939b330ba9833045f52e66d81a53
Author: Philip Withnall <philip tecnocode co uk>
Date:   Sat Jul 2 12:39:56 2011 +0100

    Fix testing of undefined macro constants to check for definedness instead
    
    Reviewed-By: Robert Bragg <robert linux intel com>

 cogl/cogl-fixed.c            |    2 +-
 cogl/cogl-framebuffer.h      |    4 ++--
 cogl/cogl-renderer-private.h |    4 ++--
 cogl/cogl.h                  |    2 +-
 4 files changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/cogl/cogl-fixed.c b/cogl/cogl-fixed.c
index 99c7d5b..7be9c3d 100644
--- a/cogl/cogl-fixed.c
+++ b/cogl/cogl-fixed.c
@@ -626,7 +626,7 @@ cogl_fixed_sqrt (CoglFixed x)
 	/*
 	 * Find the highest bit set
 	 */
-#if __arm__
+#if defined (__arm__)
 	/* This actually requires at least arm v5, but gcc does not seem
 	 * to set the architecture defines correctly, and it is I think
 	 * very unlikely that anyone will want to use clutter on anything
diff --git a/cogl/cogl-framebuffer.h b/cogl/cogl-framebuffer.h
index 7e31f22..a3795d2 100644
--- a/cogl/cogl-framebuffer.h
+++ b/cogl/cogl-framebuffer.h
@@ -34,7 +34,7 @@
 #include <windows.h>
 #endif /* COGL_HAS_WIN32_SUPPORT */
 
-#if COGL_HAS_EGL_PLATFORM_WAYLAND_SUPPORT
+#if defined (COGL_HAS_EGL_PLATFORM_WAYLAND_SUPPORT)
 #include <wayland-client.h>
 #endif /* COGL_HAS_EGL_PLATFORM_WAYLAND_SUPPORT */
 
@@ -379,7 +379,7 @@ HWND
 cogl_win32_onscreen_get_window (CoglOnscreen *onscreen);
 #endif /* COGL_HAS_WIN32_SUPPORT */
 
-#if COGL_HAS_EGL_PLATFORM_WAYLAND_SUPPORT
+#if defined (COGL_HAS_EGL_PLATFORM_WAYLAND_SUPPORT)
 struct wl_surface *
 cogl_wayland_onscreen_get_surface (CoglOnscreen *onscreen);
 #endif /* COGL_HAS_EGL_PLATFORM_WAYLAND_SUPPORT */
diff --git a/cogl/cogl-renderer-private.h b/cogl/cogl-renderer-private.h
index f85a843..45222ef 100644
--- a/cogl/cogl-renderer-private.h
+++ b/cogl/cogl-renderer-private.h
@@ -34,7 +34,7 @@
 #include <X11/Xlib.h>
 #endif
 
-#if COGL_HAS_EGL_PLATFORM_WAYLAND_SUPPORT
+#if defined (COGL_HAS_EGL_PLATFORM_WAYLAND_SUPPORT)
 #include <wayland-client.h>
 #endif
 
@@ -53,7 +53,7 @@ struct _CoglRenderer
   GModule *libgl_module;
 #endif
 
-#if COGL_HAS_EGL_PLATFORM_WAYLAND_SUPPORT
+#if defined (COGL_HAS_EGL_PLATFORM_WAYLAND_SUPPORT)
   struct wl_display *foreign_wayland_display;
   struct wl_compositor *foreign_wayland_compositor;
 #endif
diff --git a/cogl/cogl.h b/cogl/cogl.h
index 6c783d3..5def211 100644
--- a/cogl/cogl.h
+++ b/cogl/cogl.h
@@ -93,7 +93,7 @@ typedef struct _CoglFramebuffer CoglFramebuffer;
 #include <cogl/cogl-xlib.h>
 #include <cogl/cogl-xlib-renderer.h>
 #endif
-#if COGL_HAS_EGL_PLATFORM_WAYLAND_SUPPORT
+#if defined (COGL_HAS_EGL_PLATFORM_WAYLAND_SUPPORT)
 #include <cogl/cogl-wayland-renderer.h>
 #endif
 /* XXX: This will definitly go away once all the Clutter winsys



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]