diff options
Diffstat (limited to 'meson.build')
-rw-r--r-- | meson.build | 17 |
1 files changed, 5 insertions, 12 deletions
diff --git a/meson.build b/meson.build index f8bf4f80..eb66506a 100644 --- a/meson.build +++ b/meson.build | |||
@@ -14,6 +14,7 @@ project( | |||
14 | add_project_arguments( | 14 | add_project_arguments( |
15 | [ | 15 | [ |
16 | '-DWLR_USE_UNSTABLE', | 16 | '-DWLR_USE_UNSTABLE', |
17 | '-D_POSIX_C_SOURCE=200809L', | ||
17 | 18 | ||
18 | '-Wno-unused-parameter', | 19 | '-Wno-unused-parameter', |
19 | '-Wno-unused-result', | 20 | '-Wno-unused-result', |
@@ -44,7 +45,7 @@ subproject( | |||
44 | required: false, | 45 | required: false, |
45 | version: wlroots_version, | 46 | version: wlroots_version, |
46 | ) | 47 | ) |
47 | wlroots = dependency('wlroots', version: wlroots_version) | 48 | wlroots = dependency('wlroots-0.18', version: wlroots_version, fallback: 'wlroots') |
48 | wlroots_features = { | 49 | wlroots_features = { |
49 | 'xwayland': false, | 50 | 'xwayland': false, |
50 | 'libinput_backend': false, | 51 | 'libinput_backend': false, |
@@ -56,10 +57,6 @@ foreach name, _ : wlroots_features | |||
56 | wlroots_features += { name: have } | 57 | wlroots_features += { name: have } |
57 | endforeach | 58 | endforeach |
58 | 59 | ||
59 | if get_option('xwayland').enabled() and not wlroots_features['xwayland'] | ||
60 | error('Cannot enable Xwayland in sway: wlroots has been built without Xwayland support') | ||
61 | endif | ||
62 | |||
63 | null_dep = dependency('', required: false) | 60 | null_dep = dependency('', required: false) |
64 | 61 | ||
65 | jsonc = dependency('json-c', version: '>=0.13') | 62 | jsonc = dependency('json-c', version: '>=0.13') |
@@ -67,7 +64,7 @@ pcre2 = dependency('libpcre2-8') | |||
67 | wayland_server = dependency('wayland-server', version: '>=1.21.0') | 64 | wayland_server = dependency('wayland-server', version: '>=1.21.0') |
68 | wayland_client = dependency('wayland-client') | 65 | wayland_client = dependency('wayland-client') |
69 | wayland_cursor = dependency('wayland-cursor') | 66 | wayland_cursor = dependency('wayland-cursor') |
70 | wayland_protos = dependency('wayland-protocols', version: '>=1.24') | 67 | wayland_protos = dependency('wayland-protocols', version: '>=1.24', default_options: ['tests=false']) |
71 | xkbcommon = dependency('xkbcommon', version: '>=1.5.0') | 68 | xkbcommon = dependency('xkbcommon', version: '>=1.5.0') |
72 | cairo = dependency('cairo') | 69 | cairo = dependency('cairo') |
73 | pango = dependency('pango') | 70 | pango = dependency('pango') |
@@ -76,16 +73,14 @@ gdk_pixbuf = dependency('gdk-pixbuf-2.0', required: get_option('gdk-pixbuf')) | |||
76 | pixman = dependency('pixman-1') | 73 | pixman = dependency('pixman-1') |
77 | libevdev = dependency('libevdev') | 74 | libevdev = dependency('libevdev') |
78 | libinput = wlroots_features['libinput_backend'] ? dependency('libinput', version: '>=1.21.0') : null_dep | 75 | libinput = wlroots_features['libinput_backend'] ? dependency('libinput', version: '>=1.21.0') : null_dep |
79 | xcb = dependency('xcb', required: get_option('xwayland')) | 76 | xcb = wlroots_features['xwayland'] ? dependency('xcb') : null_dep |
80 | drm = dependency('libdrm') | 77 | drm = dependency('libdrm') |
81 | libudev = wlroots_features['libinput_backend'] ? dependency('libudev') : null_dep | 78 | libudev = wlroots_features['libinput_backend'] ? dependency('libudev') : null_dep |
82 | math = cc.find_library('m') | 79 | math = cc.find_library('m') |
83 | rt = cc.find_library('rt') | 80 | rt = cc.find_library('rt') |
84 | xcb_icccm = dependency('xcb-icccm', required: get_option('xwayland')) | 81 | xcb_icccm = wlroots_features['xwayland'] ? dependency('xcb-icccm') : null_dep |
85 | threads = dependency('threads') # for pthread_setschedparam | 82 | threads = dependency('threads') # for pthread_setschedparam |
86 | 83 | ||
87 | have_xwayland = xcb.found() and xcb_icccm.found() and wlroots_features['xwayland'] | ||
88 | |||
89 | if get_option('sd-bus-provider') == 'auto' | 84 | if get_option('sd-bus-provider') == 'auto' |
90 | if not get_option('tray').disabled() | 85 | if not get_option('tray').disabled() |
91 | assert(get_option('auto_features').auto(), 'sd-bus-provider must not be set to auto since auto_features != auto') | 86 | assert(get_option('auto_features').auto(), 'sd-bus-provider must not be set to auto since auto_features != auto') |
@@ -109,7 +104,6 @@ have_tray = (not get_option('tray').disabled()) and tray_deps_found | |||
109 | 104 | ||
110 | conf_data = configuration_data() | 105 | conf_data = configuration_data() |
111 | 106 | ||
112 | conf_data.set10('HAVE_XWAYLAND', have_xwayland) | ||
113 | conf_data.set10('HAVE_GDK_PIXBUF', gdk_pixbuf.found()) | 107 | conf_data.set10('HAVE_GDK_PIXBUF', gdk_pixbuf.found()) |
114 | conf_data.set10('HAVE_LIBSYSTEMD', sdbus.found() and sdbus.name() == 'libsystemd') | 108 | conf_data.set10('HAVE_LIBSYSTEMD', sdbus.found() and sdbus.name() == 'libsystemd') |
115 | conf_data.set10('HAVE_LIBELOGIND', sdbus.found() and sdbus.name() == 'libelogind') | 109 | conf_data.set10('HAVE_LIBELOGIND', sdbus.found() and sdbus.name() == 'libelogind') |
@@ -270,7 +264,6 @@ endif | |||
270 | subdir('completions') | 264 | subdir('completions') |
271 | 265 | ||
272 | summary({ | 266 | summary({ |
273 | 'xwayland': have_xwayland, | ||
274 | 'gdk-pixbuf': gdk_pixbuf.found(), | 267 | 'gdk-pixbuf': gdk_pixbuf.found(), |
275 | 'tray': have_tray, | 268 | 'tray': have_tray, |
276 | 'man-pages': scdoc.found(), | 269 | 'man-pages': scdoc.found(), |