aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/backend/backends.py
diff options
context:
space:
mode:
Diffstat (limited to 'mesonbuild/backend/backends.py')
-rw-r--r--mesonbuild/backend/backends.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/mesonbuild/backend/backends.py b/mesonbuild/backend/backends.py
index bc49966..05a3565 100644
--- a/mesonbuild/backend/backends.py
+++ b/mesonbuild/backend/backends.py
@@ -92,6 +92,7 @@ class Backend():
raise RuntimeError('No specified compiler can handle file ' + src)
def get_target_filename(self, target):
+ assert(isinstance(target, (build.BuildTarget, build.CustomTarget)))
targetdir = self.get_target_dir(target)
fname = target.get_filename()
if isinstance(fname, list):
@@ -101,6 +102,9 @@ class Backend():
filename = os.path.join(targetdir, fname)
return filename
+ def get_target_filename_abs(self, target):
+ return os.path.join(self.environment.get_build_dir(), self.get_target_filename(target))
+
def get_target_filename_for_linking(self, target):
# On some platforms (msvc for instance), the file that is used for
# dynamic linking is not the same as the dynamic library itself. This