aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dependencies.py2
-rw-r--r--interpreter.py8
2 files changed, 9 insertions, 1 deletions
diff --git a/dependencies.py b/dependencies.py
index 3a47357..c4c046a 100644
--- a/dependencies.py
+++ b/dependencies.py
@@ -825,7 +825,7 @@ why. As a hack filter out everything that is not a flag."""
return self.libs
class AppleFrameworks(Dependency):
- def __init__(self, kwargs):
+ def __init__(self, environment, kwargs):
Dependency.__init__(self)
modules = kwargs.get('modules', [])
if isinstance(modules, str):
diff --git a/interpreter.py b/interpreter.py
index 98b5175..79510dd 100644
--- a/interpreter.py
+++ b/interpreter.py
@@ -679,6 +679,8 @@ class MesonMain(InterpreterObject):
'is_subproject' : self.is_subproject_method,
'current_source_dir' : self.current_source_dir_method,
'current_build_dir' : self.current_build_dir_method,
+ 'source_root' : self.source_root_method,
+ 'build_root' : self.build_root_method,
'set_install_script' : self.set_install_script_method,
})
@@ -707,6 +709,12 @@ class MesonMain(InterpreterObject):
return src
return os.path.join(src, sub)
+ def source_root_method(self, args, kwargs):
+ return self.interpreter.environment.source_dir
+
+ def build_root_method(self, args, kwargs):
+ return self.interpreter.environment.build_dir
+
def has_exe_wrapper_method(self, args, kwargs):
if self.is_cross_build_method(None, None):
return 'exe_wrap' in self.build.environment.cross_info