diff options
author | Greg V <[email protected]> | 2018-01-19 00:48:30 +0300 |
---|---|---|
committer | Eric Engestrom <[email protected]> | 2019-08-08 21:44:33 +0100 |
commit | c0dc5c1859b665164a34028649ffaf4a2712b212 (patch) | |
tree | 7c5e6096e4053fb7014a5f6f86e66612fa309a3f | |
parent | 28061e0ab03dcbcaad32c66fa8f427d94a09c5a0 (diff) |
meson: define ETIME to ETIMEDOUT if not present
Reviewed-by: Eric Engestrom <[email protected]>
-rw-r--r-- | meson.build | 5 | ||||
-rw-r--r-- | src/gallium/drivers/iris/iris_bufmgr.c | 3 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_bufmgr.c | 3 |
3 files changed, 5 insertions, 6 deletions
diff --git a/meson.build b/meson.build index 593bfeebd5a..06953b364a8 100644 --- a/meson.build +++ b/meson.build @@ -778,6 +778,11 @@ if cc.get_id() == 'gcc' and cc.version().version_compare('< 4.4.6') error('When using GCC, version 4.4.6 or later is required.') endif +# Support systems without ETIME (e.g. FreeBSD) +if cc.get_define('ETIME', prefix : '#include <errno.h>') == '' + pre_args += '-DETIME=ETIMEDOUT' +endif + # Define DEBUG for debug builds only (debugoptimized is not included on this one) if get_option('buildtype') == 'debug' pre_args += '-DDEBUG' diff --git a/src/gallium/drivers/iris/iris_bufmgr.c b/src/gallium/drivers/iris/iris_bufmgr.c index d5e7a1e85ba..e34c8f34912 100644 --- a/src/gallium/drivers/iris/iris_bufmgr.c +++ b/src/gallium/drivers/iris/iris_bufmgr.c @@ -51,9 +51,6 @@ #include <time.h> #include "errno.h" -#ifndef ETIME -#define ETIME ETIMEDOUT -#endif #include "common/gen_clflush.h" #include "dev/gen_debug.h" #include "common/gen_gem.h" diff --git a/src/mesa/drivers/dri/i965/brw_bufmgr.c b/src/mesa/drivers/dri/i965/brw_bufmgr.c index a7c68406315..c19e87fd82e 100644 --- a/src/mesa/drivers/dri/i965/brw_bufmgr.c +++ b/src/mesa/drivers/dri/i965/brw_bufmgr.c @@ -49,9 +49,6 @@ #include <stdbool.h> #include "errno.h" -#ifndef ETIME -#define ETIME ETIMEDOUT -#endif #include "common/gen_clflush.h" #include "dev/gen_debug.h" #include "common/gen_gem.h" |