Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/videolan/dav1d.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Lhomme <slhomme@videolan.org>2018-09-28 14:06:05 +0300
committerJean-Baptiste Kempf <jb@videolan.org>2018-09-29 17:41:59 +0300
commite72c2e45748a9f80223d57333772419f00fc4e7e (patch)
tree7786cd202d52bb2ce89a88dcdd34ff3617da92fc /meson.build
parent74c9802f42842d458165f5acedc5307fda383f7b (diff)
add simplistic stdatomic.h compatible with MSVC
Only the functions needed with the current code are defined. The header will not work with other compilers. It will need to be updated for each compiler that doesn't have stdatomic.h.
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build10
1 files changed, 9 insertions, 1 deletions
diff --git a/meson.build b/meson.build
index 07e02d1..1d47dfa 100644
--- a/meson.build
+++ b/meson.build
@@ -92,8 +92,16 @@ endif
# Header checks
+stdatomic_dependency = []
if not cc.check_header('stdatomic.h')
- error('Atomics not supported')
+ if cc.get_id() == 'msvc'
+ # we have a custom replacement for MSVC
+ stdatomic_dependency = declare_dependency(
+ include_directories : include_directories('include/compat'),
+ )
+ else
+ error('Atomics not supported')
+ endif
endif
if cc.check_header('unistd.h')