From e067c4a79d356105e8a636a2a4f5979e9ab3689d Mon Sep 17 00:00:00 2001 From: Nicolas Schneider Date: Tue, 15 Mar 2016 23:26:12 +0100 Subject: [PATCH] fix eval_custom_target_command() to use absolute paths for output files --- mesonbuild/backend/backends.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/mesonbuild/backend/backends.py b/mesonbuild/backend/backends.py index 286afa924..5c2f70916 100644 --- a/mesonbuild/backend/backends.py +++ b/mesonbuild/backend/backends.py @@ -381,7 +381,11 @@ class Backend(): return exe_arr def eval_custom_target_command(self, target, absolute_paths=False): - ofilenames = [os.path.join(self.get_target_dir(target), i) for i in target.output] + if not absolute_paths: + ofilenames = [os.path.join(self.get_target_dir(target), i) for i in target.output] + else: + ofilenames = [os.path.join(self.environment.get_build_dir(), self.get_target_dir(target), i) \ + for i in target.output] srcs = [] outdir = self.get_target_dir(target) # Many external programs fail on empty arguments.