summaryrefslogtreecommitdiffstats
path: root/meson.build
diff options
context:
space:
mode:
authorDylan Baker <[email protected]>2017-10-26 15:45:40 -0700
committerDylan Baker <[email protected]>2017-11-28 14:06:38 -0800
commit43b0e5f5cd87b3ca4dc97a6373cbee1f1f129f06 (patch)
tree47ca49cc9047109bcd390480d6ec26dd680dd373 /meson.build
parenta537231b226280bc1e5b7f0f58707cbd2cf29848 (diff)
meson: build virgl driver
Build tested only. Signed-off-by: Dylan Baker <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build16
1 files changed, 11 insertions, 5 deletions
diff --git a/meson.build b/meson.build
index 956d695373d..e2ba3cb0524 100644
--- a/meson.build
+++ b/meson.build
@@ -123,14 +123,15 @@ with_gallium_etnaviv = false
with_gallium_imx = false
with_gallium_i915 = false
with_gallium_svga = false
+with_gallium_virgl = false
_drivers = get_option('gallium-drivers')
if _drivers == 'auto'
if not ['darwin', 'windows'].contains(host_machine.system())
# TODO: PPC, Sparc
if ['x86', 'x86_64'].contains(host_machine.cpu_family())
- _drivers = 'r300,r600,radeonsi,nouveau,svga,swrast'
+ _drivers = 'r300,r600,radeonsi,nouveau,virgl,svga,swrast'
elif ['arm', 'aarch64'].contains(host_machine.cpu_family())
- _drivers = 'pl111,vc4,vc5,freedreno,etnaviv,imx,svga,swrast'
+ _drivers = 'pl111,vc4,vc5,freedreno,etnaviv,imx,virgl,svga,swrast'
else
error('Unknown architecture. Please pass -Dgallium-drivers to set driver options. Patches gladly accepted to fix this.')
endif
@@ -153,6 +154,7 @@ if _drivers != ''
with_gallium_imx = _split.contains('imx')
with_gallium_i915 = _split.contains('i915')
with_gallium_svga = _split.contains('svga')
+ with_gallium_virgl = _split.contains('virgl')
with_gallium = true
endif
@@ -286,9 +288,13 @@ else
with_egl = false
endif
-# TODO: or virgl
-if with_egl and with_gallium_radeonsi and not (with_platform_drm or with_platform_surfaceless)
- error('RadeonSI requires drm or surfaceless platform when using EGL')
+if with_egl and not (with_platform_drm or with_platform_surfaceless)
+ if with_gallium_radeonsi
+ error('RadeonSI requires drm or surfaceless platform when using EGL')
+ endif
+ if with_gallium_virgl
+ error('Virgl requires drm or surfaceless platform when using EGL')
+ endif
endif
pre_args += '-DGLX_USE_TLS'