aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/dependencies/qt.py
diff options
context:
space:
mode:
authorDylan Baker <dylan@pnwbakers.com>2021-12-06 14:27:44 -0800
committerEli Schwartz <eschwartz93@gmail.com>2022-01-18 17:53:29 -0500
commit6b272973e07596b48ac95e4adaa0df9118b73b00 (patch)
treed8ea4b3d56e756d5252bd512018572b48862da4a /mesonbuild/dependencies/qt.py
parentab9c0c17356eb05078f1ae5d876638b4620d0148 (diff)
downloadmeson-6b272973e07596b48ac95e4adaa0df9118b73b00.zip
meson-6b272973e07596b48ac95e4adaa0df9118b73b00.tar.gz
meson-6b272973e07596b48ac95e4adaa0df9118b73b00.tar.bz2
dependencies: don't pass kwargs from get_pkgconfig_variable
This is a layering violation, we're relying on the way the interpreter handles keyword arguments. Instead, pass them as free variables, destructuring in the interpreter
Diffstat (limited to 'mesonbuild/dependencies/qt.py')
-rw-r--r--mesonbuild/dependencies/qt.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/mesonbuild/dependencies/qt.py b/mesonbuild/dependencies/qt.py
index 9dc928c..a004688 100644
--- a/mesonbuild/dependencies/qt.py
+++ b/mesonbuild/dependencies/qt.py
@@ -181,7 +181,7 @@ class QtPkgConfigDependency(_QtBase, PkgConfigDependency, metaclass=abc.ABCMeta)
self.is_found = False
return
if self.private_headers:
- qt_inc_dir = mod.get_pkgconfig_variable('includedir', {})
+ qt_inc_dir = mod.get_pkgconfig_variable('includedir', [], None)
mod_private_dir = os.path.join(qt_inc_dir, 'Qt' + m)
if not os.path.isdir(mod_private_dir):
# At least some versions of homebrew don't seem to set this
@@ -203,7 +203,7 @@ class QtPkgConfigDependency(_QtBase, PkgConfigDependency, metaclass=abc.ABCMeta)
if arg == f'-l{debug_lib_name}' or arg.endswith(f'{debug_lib_name}.lib') or arg.endswith(f'{debug_lib_name}.a'):
is_debug = True
break
- libdir = self.get_pkgconfig_variable('libdir', {})
+ libdir = self.get_pkgconfig_variable('libdir', [], None)
if not self._link_with_qtmain(is_debug, libdir):
self.is_found = False
return
@@ -211,7 +211,7 @@ class QtPkgConfigDependency(_QtBase, PkgConfigDependency, metaclass=abc.ABCMeta)
self.bindir = self.get_pkgconfig_host_bins(self)
if not self.bindir:
# If exec_prefix is not defined, the pkg-config file is broken
- prefix = self.get_pkgconfig_variable('exec_prefix', {})
+ prefix = self.get_pkgconfig_variable('exec_prefix', [], None)
if prefix:
self.bindir = os.path.join(prefix, 'bin')
@@ -387,7 +387,7 @@ class Qt4PkgConfigDependency(QtPkgConfigDependency):
applications = ['moc', 'uic', 'rcc', 'lupdate', 'lrelease']
for application in applications:
try:
- return os.path.dirname(core.get_pkgconfig_variable(f'{application}_location', {}))
+ return os.path.dirname(core.get_pkgconfig_variable(f'{application}_location', [], None))
except mesonlib.MesonException:
pass
return None
@@ -400,7 +400,7 @@ class Qt5PkgConfigDependency(QtPkgConfigDependency):
@staticmethod
def get_pkgconfig_host_bins(core: PkgConfigDependency) -> str:
- return core.get_pkgconfig_variable('host_bins', {})
+ return core.get_pkgconfig_variable('host_bins', [], None)
def get_private_includes(self, mod_inc_dir: str, module: str) -> T.List[str]:
return _qt_get_private_includes(mod_inc_dir, module, self.version)
@@ -410,7 +410,7 @@ class Qt6PkgConfigDependency(QtPkgConfigDependency):
@staticmethod
def get_pkgconfig_host_bins(core: PkgConfigDependency) -> str:
- return core.get_pkgconfig_variable('host_bins', {})
+ return core.get_pkgconfig_variable('host_bins', [], None)
def get_private_includes(self, mod_inc_dir: str, module: str) -> T.List[str]:
return _qt_get_private_includes(mod_inc_dir, module, self.version)