aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild
diff options
context:
space:
mode:
authorIñigo Martínez <inigomartinez@gmail.com>2017-12-01 13:49:01 +0100
committerIñigo Martínez <inigomartinez@gmail.com>2017-12-01 13:49:01 +0100
commit44dd429ee5dd6d6efb04a1097c091077f9bcf6b9 (patch)
treef82dc213d7f90f5a479bff49c17e09a2bf3d60c8 /mesonbuild
parent732aae73c6f66f0578a151c57b24ce0bd9b63bf1 (diff)
downloadmeson-44dd429ee5dd6d6efb04a1097c091077f9bcf6b9.zip
meson-44dd429ee5dd6d6efb04a1097c091077f9bcf6b9.tar.gz
meson-44dd429ee5dd6d6efb04a1097c091077f9bcf6b9.tar.bz2
dependencies: Fix pkg-config variable definition
In a previous commit variable definition was added in pkg-config. However, this commit was not complete. This fixes the missing parts of that commit.
Diffstat (limited to 'mesonbuild')
-rw-r--r--mesonbuild/dependencies/ui.py6
-rw-r--r--mesonbuild/modules/gnome.py4
2 files changed, 5 insertions, 5 deletions
diff --git a/mesonbuild/dependencies/ui.py b/mesonbuild/dependencies/ui.py
index 3412dc6..d19d07e 100644
--- a/mesonbuild/dependencies/ui.py
+++ b/mesonbuild/dependencies/ui.py
@@ -240,7 +240,7 @@ class QtBaseDependency(ExternalDependency):
self.bindir = self.get_pkgconfig_host_bins(core)
if not self.bindir:
# If exec_prefix is not defined, the pkg-config file is broken
- prefix = core.get_pkgconfig_variable('exec_prefix')
+ prefix = core.get_pkgconfig_variable('exec_prefix', {})
if prefix:
self.bindir = os.path.join(prefix, 'bin')
@@ -360,7 +360,7 @@ class Qt4Dependency(QtBaseDependency):
applications = ['moc', 'uic', 'rcc', 'lupdate', 'lrelease']
for application in applications:
try:
- return os.path.dirname(core.get_pkgconfig_variable('%s_location' % application))
+ return os.path.dirname(core.get_pkgconfig_variable('%s_location' % application, {}))
except MesonException:
pass
@@ -370,7 +370,7 @@ class Qt5Dependency(QtBaseDependency):
QtBaseDependency.__init__(self, 'qt5', env, kwargs)
def get_pkgconfig_host_bins(self, core):
- return core.get_pkgconfig_variable('host_bins')
+ return core.get_pkgconfig_variable('host_bins', {})
# There are three different ways of depending on SDL2:
diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py
index 7e61242..c80a1f1 100644
--- a/mesonbuild/modules/gnome.py
+++ b/mesonbuild/modules/gnome.py
@@ -370,7 +370,7 @@ class GnomeModule(ExtensionModule):
ldflags.update([lib])
if isinstance(dep, PkgConfigDependency):
- girdir = dep.get_pkgconfig_variable("girdir")
+ girdir = dep.get_pkgconfig_variable("girdir", {})
if girdir:
gi_includes.update([girdir])
elif isinstance(dep, (build.StaticLibrary, build.SharedLibrary)):
@@ -561,7 +561,7 @@ class GnomeModule(ExtensionModule):
if subdir not in typelib_includes:
typelib_includes.append(subdir)
elif isinstance(dep, PkgConfigDependency):
- girdir = dep.get_pkgconfig_variable("girdir")
+ girdir = dep.get_pkgconfig_variable("girdir", {})
if girdir and girdir not in typelib_includes:
typelib_includes.append(girdir)
# ldflags will be misinterpreted by gir scanner (showing