aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/dependencies/misc.py
diff options
context:
space:
mode:
authorDylan Baker <dylan@pnwbakers.com>2019-04-05 16:41:08 -0700
committerDylan Baker <dylan@pnwbakers.com>2019-04-05 16:41:08 -0700
commit6ad7fbf9509dd68792df7df08b785967a067d4c4 (patch)
treed4ed3b440daefa52c8fe9301c92505a53e96f49f /mesonbuild/dependencies/misc.py
parentb842b0b04aa8678f98cbec5f7022e75636ddf4a3 (diff)
downloadmeson-6ad7fbf9509dd68792df7df08b785967a067d4c4.zip
meson-6ad7fbf9509dd68792df7df08b785967a067d4c4.tar.gz
meson-6ad7fbf9509dd68792df7df08b785967a067d4c4.tar.bz2
dependencies/misc: don't special case threads
Instad of having special casing of threads in the backends and everywehre else, do what we did for openmp, create a real dependency. Then make use of the fact that dependencies can now have sub dependencies to add threads.
Diffstat (limited to 'mesonbuild/dependencies/misc.py')
-rw-r--r--mesonbuild/dependencies/misc.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/mesonbuild/dependencies/misc.py b/mesonbuild/dependencies/misc.py
index 76eccfb..5721cc3 100644
--- a/mesonbuild/dependencies/misc.py
+++ b/mesonbuild/dependencies/misc.py
@@ -385,9 +385,8 @@ class ThreadDependency(ExternalDependency):
super().__init__('threads', environment, None, kwargs)
self.name = 'threads'
self.is_found = True
-
- def need_threads(self):
- return True
+ self.compile_args = self.clib_compiler.thread_flags(environment)
+ self.link_args = self.clib_compiler.thread_link_flags(environment)
class Python3Dependency(ExternalDependency):