dependencies: Use the _add_sub_dependency

pull/5254/head
Dylan Baker 6 years ago
parent 0654b1a2b1
commit b59bec08a2
  1. 2
      mesonbuild/dependencies/boost.py
  2. 6
      mesonbuild/dependencies/dev.py

@ -105,7 +105,7 @@ class BoostDependency(ExternalDependency):
self.requested_modules = self.get_requested(kwargs)
if 'thread' in self.requested_modules:
self.ext_deps.append(ThreadDependency(environment, kwargs))
self._add_sub_dependency(ThreadDependency, environment, kwargs)
self.boost_root = None
self.boost_roots = []

@ -46,7 +46,7 @@ class GTestDependency(ExternalDependency):
self.main = kwargs.get('main', False)
self.src_dirs = ['/usr/src/gtest/src', '/usr/src/googletest/googletest/src']
self.detect()
self.ext_deps.append(ThreadDependency(environment, kwargs))
self._add_sub_dependency(ThreadDependency, environment, kwargs)
def detect(self):
gtest_detect = self.clib_compiler.find_library("gtest", self.env, [])
@ -117,7 +117,7 @@ class GMockDependency(ExternalDependency):
def __init__(self, environment, kwargs):
super().__init__('gmock', environment, 'cpp', kwargs)
self.main = kwargs.get('main', False)
self.ext_deps.append(ThreadDependency(environment, kwargs))
self._add_sub_dependency(ThreadDependency, environment, kwargs)
# If we are getting main() from GMock, we definitely
# want to avoid linking in main() from GTest
@ -256,7 +256,7 @@ class LLVMDependency(ConfigToolDependency):
self._set_old_link_args()
self.link_args = strip_system_libdirs(environment, self.link_args)
self.link_args = self.__fix_bogus_link_args(self.link_args)
self.ext_deps.append(ThreadDependency(environment, kwargs))
self._add_sub_dependency(ThreadDependency, environment, kwargs)
@staticmethod
def __fix_bogus_link_args(args):

Loading…
Cancel
Save