summaryrefslogtreecommitdiffstats
path: root/wscript
diff options
context:
space:
mode:
authorAlessandro Ghedini <alessandro@ghedini.me>2013-12-30 16:30:30 +0100
committerStefano Pigozzi <stefano.pigozzi@gmail.com>2013-12-31 10:53:36 +0100
commite19060d89f219fda16d3bd86e2b3db472f884c98 (patch)
treeb9b8a6a2b026b11e12e43b26e972005e6ecf1f37 /wscript
parent548aa811960fa43a5fdf655719fa5065ec4f2f50 (diff)
downloadmpv-e19060d89f219fda16d3bd86e2b3db472f884c98.tar.bz2
mpv-e19060d89f219fda16d3bd86e2b3db472f884c98.tar.xz
build: check for libatomic and __atomic operations
Add check in old-configure as well. Reformat the check to use a maximum of 80 columns in the wscript. Signed-off-by: Stefano Pigozzi <stefano.pigozzi@gmail.com>
Diffstat (limited to 'wscript')
-rw-r--r--wscript7
1 files changed, 7 insertions, 0 deletions
diff --git a/wscript b/wscript
index 0e23e57560..7a6ee4fb02 100644
--- a/wscript
+++ b/wscript
@@ -99,6 +99,13 @@ main_dependencies = [
'req': True,
'fmsg': 'Unable to find pthreads support.'
}, {
+ 'name': 'atomic_builtins',
+ 'desc': 'compiler support for __atomic built-ins',
+ 'func': check_libs(['atomic'],
+ check_statement('stdint.h',
+ 'int64_t test = 0;'
+ 'test = __atomic_add_fetch(&test, 1, __ATOMIC_SEQ_CST)'))
+ }, {
'name': 'librt',
'desc': 'linking with -lrt',
'deps': [ 'pthreads' ],