Andrew Geissler | 95ac1b8 | 2021-03-31 14:34:31 -0500 | [diff] [blame] | 1 | From 38e984073e4c23b6278d1a2ff21e894fda7b93c5 Mon Sep 17 00:00:00 2001 |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 2 | From: Alistair Francis <alistair@alistair23.me> |
| 3 | Date: Thu, 14 Nov 2019 13:04:49 -0800 |
Brad Bishop | a34c030 | 2019-09-23 22:34:48 -0400 | [diff] [blame] | 4 | Subject: [PATCH] meson.build: check for all linux host_os combinations |
Brad Bishop | 393846f | 2019-05-20 12:24:11 -0400 | [diff] [blame] | 5 | |
| 6 | Make sure that we are also looking for our host_os combinations like |
| 7 | linux-musl etc. when assuming support for DRM/KMS. |
| 8 | |
| 9 | Also delete a duplicate line. |
| 10 | |
Brad Bishop | 15ae250 | 2019-06-18 21:44:24 -0400 | [diff] [blame] | 11 | Upstream-Status: Pending |
| 12 | |
Brad Bishop | 393846f | 2019-05-20 12:24:11 -0400 | [diff] [blame] | 13 | Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> |
| 14 | Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br> |
Brad Bishop | a34c030 | 2019-09-23 22:34:48 -0400 | [diff] [blame] | 15 | Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 16 | Signed-off-by: Alistair Francis <alistair@alistair23.me> |
Brad Bishop | 6dbb316 | 2019-11-25 09:41:34 -0500 | [diff] [blame] | 17 | |
Brad Bishop | 393846f | 2019-05-20 12:24:11 -0400 | [diff] [blame] | 18 | --- |
Brad Bishop | a34c030 | 2019-09-23 22:34:48 -0400 | [diff] [blame] | 19 | meson.build | 4 ++-- |
| 20 | 1 file changed, 2 insertions(+), 2 deletions(-) |
Brad Bishop | 393846f | 2019-05-20 12:24:11 -0400 | [diff] [blame] | 21 | |
| 22 | diff --git a/meson.build b/meson.build |
Andrew Geissler | 95ac1b8 | 2021-03-31 14:34:31 -0500 | [diff] [blame] | 23 | index 932eb13..efc6171 100644 |
Brad Bishop | 393846f | 2019-05-20 12:24:11 -0400 | [diff] [blame] | 24 | --- a/meson.build |
| 25 | +++ b/meson.build |
Andrew Geissler | 95ac1b8 | 2021-03-31 14:34:31 -0500 | [diff] [blame] | 26 | @@ -153,7 +153,7 @@ with_any_opengl = with_opengl or with_gles1 or with_gles2 |
Brad Bishop | 15ae250 | 2019-06-18 21:44:24 -0400 | [diff] [blame] | 27 | # Only build shared_glapi if at least one OpenGL API is enabled |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 28 | with_shared_glapi = with_shared_glapi and with_any_opengl |
Brad Bishop | 393846f | 2019-05-20 12:24:11 -0400 | [diff] [blame] | 29 | |
Brad Bishop | 6dbb316 | 2019-11-25 09:41:34 -0500 | [diff] [blame] | 30 | -system_has_kms_drm = ['openbsd', 'netbsd', 'freebsd', 'gnu/kfreebsd', 'dragonfly', 'linux', 'sunos'].contains(host_machine.system()) |
Brad Bishop | a34c030 | 2019-09-23 22:34:48 -0400 | [diff] [blame] | 31 | +system_has_kms_drm = ['openbsd', 'netbsd', 'freebsd', 'dragonfly'].contains(host_machine.system()) or host_machine.system().startswith('linux') |
| 32 | |
Brad Bishop | 15ae250 | 2019-06-18 21:44:24 -0400 | [diff] [blame] | 33 | dri_drivers = get_option('dri-drivers') |
| 34 | if dri_drivers.contains('auto') |
Andrew Geissler | 95ac1b8 | 2021-03-31 14:34:31 -0500 | [diff] [blame] | 35 | @@ -970,7 +970,7 @@ if cc.compiles('__uint128_t foo(void) { return 0; }', |
Brad Bishop | 393846f | 2019-05-20 12:24:11 -0400 | [diff] [blame] | 36 | endif |
| 37 | |
| 38 | # TODO: this is very incomplete |
Andrew Geissler | 95ac1b8 | 2021-03-31 14:34:31 -0500 | [diff] [blame] | 39 | -if ['linux', 'cygwin', 'gnu', 'freebsd', 'gnu/kfreebsd', 'haiku'].contains(host_machine.system()) |
| 40 | +if ['linux', 'cygwin', 'gnu', 'freebsd', 'gnu/kfreebsd', 'haiku'].contains(host_machine.system()) or host_machine.system().startswith('linux') |
Brad Bishop | 393846f | 2019-05-20 12:24:11 -0400 | [diff] [blame] | 41 | pre_args += '-D_GNU_SOURCE' |
Brad Bishop | 6dbb316 | 2019-11-25 09:41:34 -0500 | [diff] [blame] | 42 | elif host_machine.system() == 'sunos' |
| 43 | pre_args += '-D__EXTENSIONS__' |