drm: Branch 'master'

[email protected] (GitLab Mirror) Thu, 5 Dec 2019 13:28:30 +0000 (UTC)
Newsgroups gmane.comp.video.dri.patches
Message-ID <[email protected]>
 meson.build |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 8de2696213d0f25a10a167b5fd6c312d6ce6a1af
Author: Peter Seiderer <[email protected]>
Date:   Mon Jul 16 23:01:40 2018 +0200

    meson.build: fix intel atomics detection
    
    Use the stronger compiler.link() test (instead of the weaker
    compiler.compile()) to fix the intel atomics detection.
    
    Fixes false positive in case of sparc compile (buildroot toolchain).
    
    Signed-off-by: Peter Seiderer <[email protected]>
    Reviewed-by: Eric Engestrom <[email protected]>

diff --git a/meson.build b/meson.build
index 677ff4f3..96ee50c5 100644
--- a/meson.build
+++ b/meson.build
@@ -52,9 +52,10 @@ intel_atomics = false
 lib_atomics = false
 
 dep_atomic_ops = dependency('atomic_ops', required : false)
-if cc.compiles('''
+if cc.links('''
     int atomic_add(int *i) { return __sync_add_and_fetch (i, 1); }
     int atomic_cmpxchg(int *i, int j, int k) { return __sync_val_compare_and_swap (i, j, k); }
+    int main() { }
     ''',
     name : 'Intel Atomics')
   intel_atomics = true


--