diff options
author | Rob Clark <[email protected]> | 2018-03-13 19:00:45 -0400 |
---|---|---|
committer | Rob Clark <[email protected]> | 2018-03-16 16:18:42 -0400 |
commit | bc5001325b876afbd9fbb7186174e085e0b06206 (patch) | |
tree | cb03303d840e2daff834a70f145f2e8469c52b3d | |
parent | 7aeef2d4efdc809a698e9b983c8be8e4ccb27134 (diff) |
meson+dri3: allow building against older xcb (v3)
Similar to previous patch, make xcb 1.13 optional.
Signed-off-by: Rob Clark <[email protected]>
Reviewed-by: Dylan Baker <[email protected]>
-rw-r--r-- | meson.build | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/meson.build b/meson.build index 557e9ef3397..a59736f50ae 100644 --- a/meson.build +++ b/meson.build @@ -1235,9 +1235,14 @@ if with_platform_x11 dep_xcb_dri2 = dependency('xcb-dri2', version : '>= 1.8') if with_dri3 - pre_args += '-DHAVE_DRI3 -DHAVE_DRI3_MODIFIERS' - dep_xcb_dri3 = dependency('xcb-dri3', version : '>= 1.13') - dep_xcb_present = dependency('xcb-present', version: '>= 1.13') + pre_args += '-DHAVE_DRI3' + dep_xcb_dri3 = dependency('xcb-dri3') + dep_xcb_present = dependency('xcb-present') + # until xcb-dri3 has been around long enough to make a hard-dependency: + if (dep_xcb_dri3.version().version_compare('>= 1.13') and + dep_xcb_present.version().version_compare('>= 1.13')) + pre_args += '-DHAVE_DRI3_MODIFIERS' + endif dep_xcb_sync = dependency('xcb-sync') dep_xshmfence = dependency('xshmfence', version : '>= 1.1') endif |