aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/compilers/c.py
diff options
context:
space:
mode:
authorMarvin Scholz <epirat07@gmail.com>2018-09-26 13:54:00 +0200
committerJussi Pakkanen <jpakkane@gmail.com>2018-09-28 12:54:10 -0700
commit843b0b1d5075f83fdd4c5e52a363f9f315c47365 (patch)
tree3ed0393258626113d57e37e7298c38152888c061 /mesonbuild/compilers/c.py
parentdc7bb37c465822b3918c7d4d942b4b32ed66d155 (diff)
downloadmeson-843b0b1d5075f83fdd4c5e52a363f9f315c47365.zip
meson-843b0b1d5075f83fdd4c5e52a363f9f315c47365.tar.gz
meson-843b0b1d5075f83fdd4c5e52a363f9f315c47365.tar.bz2
compilers: Do not use -pthread with clang for darwin
Using the -pthread argument is not needed with clang when compiling for darwin, and it results in the warning: warning: argument unused during compilation: '-pthread'
Diffstat (limited to 'mesonbuild/compilers/c.py')
-rw-r--r--mesonbuild/compilers/c.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/mesonbuild/compilers/c.py b/mesonbuild/compilers/c.py
index 7c6a43b..2da627f 100644
--- a/mesonbuild/compilers/c.py
+++ b/mesonbuild/compilers/c.py
@@ -1076,6 +1076,16 @@ class ClangCCompiler(ClangCompiler, CCompiler):
'none')})
return opts
+ def thread_flags(self, env):
+ if for_darwin(self.is_cross, env):
+ return []
+ return super().thread_flags()
+
+ def thread_link_flags(self, env):
+ if for_darwin(self.is_cross, env):
+ return []
+ return super().thread_link_flags()
+
def get_option_compile_args(self, options):
args = []
std = options['c_std']