[gtk] Do not test for linker flags



commit 69441cbaceae6fa1b5f2df150609fe59b2a67cea
Author: Emmanuele Bassi <ebassi gnome org>
Date:   Mon Mar 26 11:48:30 2018 +0100

    Do not test for linker flags
    
    Meson warns when doing that, as it's not really portable.
    
    Since we're using platform-specific linker flags on Darwin, we can also
    do the same on Linux; the syntax is GCC-specific, so we're going to need
    Clang users to test it.

 meson.build | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)
---
diff --git a/meson.build b/meson.build
index 26d522fa3b..5831dfcbfe 100644
--- a/meson.build
+++ b/meson.build
@@ -279,12 +279,8 @@ endif
 
 common_ldflags = []
 
-if host_machine.system() == 'linux'
-  foreach ldflag: [ '-Wl,-Bsymbolic', '-Wl,-z,relro', '-Wl,-z,now', ]
-    if cc.has_argument(ldflag)
-      common_ldflags += [ ldflag ]
-    endif
-  endforeach
+if host_machine.system() == 'linux' and cc.get_id() == 'gcc'
+  common_ldflags += [ '-Wl,-Bsymbolic', '-Wl,-z,relro', '-Wl,-z,now', ]
 endif
 
 # Maintain compatibility with autotools


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]