summaryrefslogtreecommitdiffstats
path: root/meta/recipes-graphics/mesa/files/0001-meson.build-check-for-all-linux-host_os-combinations.patch
blob: 61e24c6e9fa0b8ccc840c1da5fcbf9748fe0d7a7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
From 498f230c9446fc7a1b4dc77ff6b84ee1a3b53bf4 Mon Sep 17 00:00:00 2001
From: Fabio Berton <fabio.berton@ossystems.com.br>
Date: Wed, 24 Apr 2019 17:01:24 -0300
Subject: [PATCH] meson.build: check for all linux host_os combinations
Organization: O.S. Systems Software LTDA.

Make sure that we are also looking for our host_os combinations like
linux-musl etc. when assuming support for DRM/KMS.

Also delete a duplicate line.

Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br>
---
 meson.build | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/meson.build b/meson.build
index 53d02e31097..c41f6b4e402 100644
--- a/meson.build
+++ b/meson.build
@@ -34,6 +34,8 @@ cpp = meson.get_compiler('cpp')
 
 null_dep = dependency('', required : false)
 
+system_has_kms_drm = ['openbsd', 'netbsd', 'freebsd', 'dragonfly'].contains(host_machine.system()) or host_machine.system().startswith('linux')
+
 # Arguments for the preprocessor, put these in a separate array from the C and
 # C++ (cpp in meson terminology) arguments since they need to be added to the
 # default arguments for both C and C++.
@@ -89,8 +91,6 @@ if (with_gles1 or with_gles2) and not with_opengl
   error('building OpenGL ES without OpenGL is not supported.')
 endif
 
-system_has_kms_drm = ['openbsd', 'netbsd', 'freebsd', 'dragonfly', 'linux'].contains(host_machine.system())
-
 _drivers = get_option('dri-drivers')
 if _drivers.contains('auto')
   if system_has_kms_drm
@@ -792,7 +792,7 @@ if cc.compiles('int foo(void) __attribute__((__noreturn__));',
 endif
 
 # TODO: this is very incomplete
-if ['linux', 'cygwin', 'gnu'].contains(host_machine.system())
+if ['cygwin', 'gnu'].contains(host_machine.system()) or host_machine.system().startswith('linux')
   pre_args += '-D_GNU_SOURCE'
 endif
 
-- 
2.21.0