aboutsummaryrefslogtreecommitdiff
path: root/interpreter.py
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2014-02-12 22:37:25 +0200
committerJussi Pakkanen <jpakkane@gmail.com>2014-02-12 22:37:25 +0200
commit51827d4484845432588f850b24245d22b1d9c9f0 (patch)
tree3564b530787dd29902108363ddcf6753051bc619 /interpreter.py
parentd84d70fa9a490578ffa926be82edefeeed217cb7 (diff)
downloadmeson-51827d4484845432588f850b24245d22b1d9c9f0.zip
meson-51827d4484845432588f850b24245d22b1d9c9f0.tar.gz
meson-51827d4484845432588f850b24245d22b1d9c9f0.tar.bz2
Can override install directory on a target-by-target basis.
Diffstat (limited to 'interpreter.py')
-rw-r--r--interpreter.py11
1 files changed, 9 insertions, 2 deletions
diff --git a/interpreter.py b/interpreter.py
index 9f84816..1e74f40 100644
--- a/interpreter.py
+++ b/interpreter.py
@@ -52,13 +52,13 @@ class TryRunResultHolder(InterpreterObject):
def returncode_method(self, args, kwargs):
return self.res.returncode
-
+
def compiled_method(self, args, kwargs):
return self.res.compiled
def stdout_method(self, args, kwargs):
return self.res.stdout
-
+
def stderr_method(self, args, kwargs):
return self.res.stderr
@@ -267,6 +267,10 @@ class Headers(InterpreterObject):
InterpreterObject.__init__(self)
self.sources = sources
self.subdir = kwargs.get('subdir', '')
+ self.custom_install_dir = kwargs.get('install_dir', None)
+ if self.custom_install_dir is not None:
+ if not isinstance(self.custom_install_dir, str):
+ raise InterpreterException('Custom_install_dir must be a string.')
def set_subdir(self, subdir):
self.subdir = subdir
@@ -277,6 +281,9 @@ class Headers(InterpreterObject):
def get_sources(self):
return self.sources
+ def get_custom_install_dir(self):
+ return self.custom_install_dir
+
class Data(InterpreterObject):
def __init__(self, subdir, sources, kwargs):
InterpreterObject.__init__(self)