diff options
author | Kristian Høgsberg <krh@bitplanet.net> | 2014-05-12 21:34:18 -0700 |
---|---|---|
committer | Kristian Høgsberg <krh@bitplanet.net> | 2014-05-12 21:34:18 -0700 |
commit | 7076a41f927eebdd776546f2bec795288c08d594 (patch) | |
tree | 39681fa76eda8667075dbd8917e1a3d1ff5476eb | |
parent | 5e3ff49c7d4ed46c1678e640ec11f6938369c0bc (diff) | |
download | weston-1.3.tar.gz |
Fix sub-compositor duplicated symbols1.3
With moving wl_subcompositor to core wayland, we have duplicate definitions
in the headers we include from wayland and the ones we generate. Use the
WL_SUBCOMPOSITOR_ERROR_ENUM #define to conditionally include the
subsurface headers we generate.
-rw-r--r-- | clients/window.h | 3 | ||||
-rw-r--r-- | src/compositor.c | 5 | ||||
-rw-r--r-- | tests/subsurface-test.c | 5 |
3 files changed, 11 insertions, 2 deletions
diff --git a/clients/window.h b/clients/window.h index 4427ab5a..4ae60889 100644 --- a/clients/window.h +++ b/clients/window.h @@ -28,7 +28,10 @@ #include <cairo.h> #include "../shared/config-parser.h" #include "../shared/zalloc.h" + +#ifndef WL_SUBCOMPOSITOR_ERROR_ENUM #include "subsurface-client-protocol.h" +#endif #define ARRAY_LENGTH(a) (sizeof (a) / sizeof (a)[0]) diff --git a/src/compositor.c b/src/compositor.c index 36b54b5b..9c7ae1aa 100644 --- a/src/compositor.c +++ b/src/compositor.c @@ -53,11 +53,14 @@ #endif #include "compositor.h" -#include "subsurface-server-protocol.h" #include "../shared/os-compatibility.h" #include "git-version.h" #include "version.h" +#ifndef WL_SUBCOMPOSITOR_ERROR_ENUM +#include "subsurface-server-protocol.h" +#endif + static struct wl_list child_process_list; static struct weston_compositor *segv_compositor; diff --git a/tests/subsurface-test.c b/tests/subsurface-test.c index 98e00fea..99e9d6d0 100644 --- a/tests/subsurface-test.c +++ b/tests/subsurface-test.c @@ -23,9 +23,12 @@ #include <string.h> #include "weston-test-client-helper.h" -#include "subsurface-client-protocol.h" #include <stdio.h> +#ifndef WL_SUBCOMPOSITOR_ERROR_ENUM +#include "subsurface-client-protocol.h" +#endif + #define NUM_SUBSURFACES 3 struct compound_surface { |