diff --git a/include/wlr/xwayland.h b/include/wlr/xwayland.h index 0d4b91ed..f34860aa 100644 --- a/include/wlr/xwayland.h +++ b/include/wlr/xwayland.h @@ -8,10 +8,6 @@ #include #include -#ifdef WLR_HAS_XCB_ICCCM - #include -#endif - struct wlr_xwm; struct wlr_xwayland_cursor; diff --git a/include/wlr/xwm.h b/include/xwayland/xwm.h similarity index 95% rename from include/wlr/xwm.h rename to include/xwayland/xwm.h index 7d518f7e..0ed61d37 100644 --- a/include/wlr/xwm.h +++ b/include/xwayland/xwm.h @@ -5,6 +5,13 @@ #include #include +#ifdef WLR_HAS_XCB_ICCCM + #include +#endif +#ifdef WLR_HAS_XCB_ERRORS + #include +#endif + enum atom_name { WL_SURFACE_ID, WM_DELETE_WINDOW, diff --git a/meson.build b/meson.build index 1188f318..553d2b88 100644 --- a/meson.build +++ b/meson.build @@ -103,7 +103,6 @@ if get_option('enable_xwayland') conf_data.set('WLR_HAS_XWAYLAND', true) else exclude_headers += 'xwayland.h' - exclude_headers += 'xwm.h' endif exclude_headers += 'meson.build' install_subdir('include/wlr', install_dir: 'include', exclude_files: exclude_headers) diff --git a/xwayland/selection.c b/xwayland/selection.c index ffcde4d0..1d390026 100644 --- a/xwayland/selection.c +++ b/xwayland/selection.c @@ -7,8 +7,8 @@ #include #include #include -#include #include +#include "xwayland/xwm.h" static const size_t incr_chunk_size = 64 * 1024; diff --git a/xwayland/xwayland.c b/xwayland/xwayland.c index 8dffd040..d49dd718 100644 --- a/xwayland/xwayland.c +++ b/xwayland/xwayland.c @@ -18,9 +18,9 @@ #include #include #include -#include #include "sockets.h" #include "util/signal.h" +#include "xwayland/xwm.h" #ifdef __FreeBSD__ static inline int clearenv(void) { diff --git a/xwayland/xwm.c b/xwayland/xwm.c index ca6786db..b4042ad6 100644 --- a/xwayland/xwm.c +++ b/xwayland/xwm.c @@ -9,19 +9,12 @@ #include #include #include -#include #include #include #include #include #include "util/signal.h" - -#ifdef WLR_HAS_XCB_ICCCM - #include -#endif -#ifdef WLR_HAS_XCB_ERRORS - #include -#endif +#include "xwayland/xwm.h" const char *atom_map[ATOM_LAST] = { "WL_SURFACE_ID",